Package com.io7m.changelog.text.api
Class CPlainChangelogWriterConfiguration
java.lang.Object
com.io7m.changelog.text.api.CPlainChangelogWriterConfiguration
- All Implemented Interfaces:
CPlainChangelogWriterConfigurationType
public final class CPlainChangelogWriterConfiguration
extends Object
implements CPlainChangelogWriterConfigurationType
The type of configurations for plain text writers.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeCPlainChangelogWriterConfiguration. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forCPlainChangelogWriterConfiguration.copyOf(CPlainChangelogWriterConfigurationType instance) Creates an immutable copy of aCPlainChangelogWriterConfigurationTypevalue.booleanThis instance is equal to all instances ofCPlainChangelogWriterConfigurationthat have equal attribute values.inthashCode()Computes a hash code from attributes:showDates.of(boolean showDates) Construct a new immutableCPlainChangelogWriterConfigurationinstance.booleantoString()Prints the immutable valueCPlainChangelogWriterConfigurationwith attribute values.withShowDates(boolean value) Copy the current immutable object by setting a value for theshowDatesattribute.
-
Method Details
-
showDates
public boolean showDates()- Specified by:
showDatesin interfaceCPlainChangelogWriterConfigurationType- Returns:
trueif dates should be shown in the output
-
withShowDates
Copy the current immutable object by setting a value for theshowDatesattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for showDates- Returns:
- A modified copy of the
thisobject
-
equals
This instance is equal to all instances ofCPlainChangelogWriterConfigurationthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:showDates. -
toString
Prints the immutable valueCPlainChangelogWriterConfigurationwith attribute values. -
of
Construct a new immutableCPlainChangelogWriterConfigurationinstance.- Parameters:
showDates- The value for theshowDatesattribute- Returns:
- An immutable CPlainChangelogWriterConfiguration instance
-
copyOf
public static CPlainChangelogWriterConfiguration copyOf(CPlainChangelogWriterConfigurationType instance) Creates an immutable copy of aCPlainChangelogWriterConfigurationTypevalue. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance- The instance to copy- Returns:
- A copied immutable CPlainChangelogWriterConfiguration instance
-
builder
Creates a builder forCPlainChangelogWriterConfiguration.CPlainChangelogWriterConfiguration.builder() .setShowDates(boolean) // optionalshowDates.build();- Returns:
- A new CPlainChangelogWriterConfiguration builder
-