Record Class Config
java.lang.Object
java.lang.Record
io.github.startsmercury.simply_no_shading.impl.client.config.v0.Config
- Record Components:
blockShadingEnabled- Should non-entity blocks be shaded.cloudShadingEnabled- Should clouds be shaded.entityShadingEnabled- Should entities and block entities be shaded.
- All Implemented Interfaces:
IConfig
public record Config(boolean blockShadingEnabled, boolean cloudShadingEnabled, boolean entityShadingEnabled)
extends Record
implements IConfig
The Simply No Shading modification configuration, format version
0.- Since:
- 8.0.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final booleanThe field for theblockShadingEnabledrecord component.private final booleanThe field for thecloudShadingEnabledrecord component.static final com.mojang.serialization.MapCodec<Config> private final booleanThe field for theentityShadingEnabledrecord component.static final com.mojang.serialization.MapCodec<Config> static final intThe configuration format version.Fields inherited from interface io.github.startsmercury.simply_no_shading.impl.client.config.IConfig
MIN_VERSION -
Constructor Summary
ConstructorsConstructorDescriptionConfig(boolean blockShadingEnabled, boolean cloudShadingEnabled, boolean entityShadingEnabled) Creates an instance of aConfigrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of theblockShadingEnabledrecord component.booleanReturns the value of thecloudShadingEnabledrecord component.booleanReturns the value of theentityShadingEnabledrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.private static com.mojang.serialization.MapCodec<Config> newCodec(CodecFieldBuilder fieldBuilder) final StringtoString()Returns a string representation of this record class.intversion()The configuration format version.
-
Field Details
-
blockShadingEnabled
private final boolean blockShadingEnabledThe field for theblockShadingEnabledrecord component. -
cloudShadingEnabled
private final boolean cloudShadingEnabledThe field for thecloudShadingEnabledrecord component. -
entityShadingEnabled
private final boolean entityShadingEnabledThe field for theentityShadingEnabledrecord component. -
VERSION
public static final int VERSIONThe configuration format version.- See Also:
- Implementation Requirements:
- The version must be
0.
-
LENIENT_CODEC
-
CODEC
-
-
Constructor Details
-
Config
public Config(boolean blockShadingEnabled, boolean cloudShadingEnabled, boolean entityShadingEnabled) Creates an instance of aConfigrecord class.- Parameters:
blockShadingEnabled- the value for theblockShadingEnabledrecord componentcloudShadingEnabled- the value for thecloudShadingEnabledrecord componententityShadingEnabled- the value for theentityShadingEnabledrecord component
-
-
Method Details
-
version
public int version()Description copied from interface:IConfigThe configuration format version. -
newCodec
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with '=='. -
blockShadingEnabled
public boolean blockShadingEnabled()Returns the value of theblockShadingEnabledrecord component.- Returns:
- the value of the
blockShadingEnabledrecord component
-
cloudShadingEnabled
public boolean cloudShadingEnabled()Returns the value of thecloudShadingEnabledrecord component.- Returns:
- the value of the
cloudShadingEnabledrecord component
-
entityShadingEnabled
public boolean entityShadingEnabled()Returns the value of theentityShadingEnabledrecord component.- Returns:
- the value of the
entityShadingEnabledrecord component
-