Package net.minecraft.test
Record Class TestEnvironmentDefinition.GameRules
java.lang.Object
java.lang.Record
net.minecraft.test.TestEnvironmentDefinition.GameRules
- Record Components:
gameRulesMap-
- All Implemented Interfaces:
TestEnvironmentDefinition
- Enclosing interface:
TestEnvironmentDefinition
public static record TestEnvironmentDefinition.GameRules(ServerGameRules gameRulesMap)
extends Record
implements TestEnvironmentDefinition
- Mappings:
Namespace Name named net/minecraft/test/TestEnvironmentDefinition$GameRulesintermediary net/minecraft/class_10665$class_10668official tw$cnamed gameRulesMapintermediary comp_5194official d
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.test.TestEnvironmentDefinition
TestEnvironmentDefinition.AllOf, TestEnvironmentDefinition.Function, TestEnvironmentDefinition.GameRules, TestEnvironmentDefinition.TimeOfDay, TestEnvironmentDefinition.Weather -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.MapCodec<TestEnvironmentDefinition.GameRules> private final ServerGameRulesThe field for thegameRulesMaprecord component.Fields inherited from interface net.minecraft.test.TestEnvironmentDefinition
ENTRY_CODEC -
Constructor Summary
ConstructorsConstructorDescriptionGameRules(ServerGameRules gameRulesMap) Creates an instance of aGameRulesrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.Returns the value of thegameRulesMaprecord component.com.mojang.serialization.MapCodec<TestEnvironmentDefinition.GameRules> getCodec()final inthashCode()Returns a hash code value for this object.private <T> voidresetValue(ServerWorld serverWorld, GameRule<T> rule) voidsetup(ServerWorld world) voidteardown(ServerWorld world) final StringtoString()Returns a string representation of this record class.
-
Field Details
-
gameRulesMap
The field for thegameRulesMaprecord component. -
CODEC
- Mappings:
Namespace Name Mixin selector named CODECLnet/minecraft/test/TestEnvironmentDefinition$GameRules;CODEC:Lcom/mojang/serialization/MapCodec;intermediary field_56205Lnet/minecraft/class_10665$class_10668;field_56205:Lcom/mojang/serialization/MapCodec;official cLtw$c;c:Lcom/mojang/serialization/MapCodec;
-
-
Constructor Details
-
GameRules
Creates an instance of aGameRulesrecord class.- Parameters:
gameRulesMap- the value for thegameRulesMaprecord component
-
-
Method Details
-
setup
- Specified by:
setupin interfaceTestEnvironmentDefinition- Mappings:
Namespace Name Mixin selector named setupLnet/minecraft/test/TestEnvironmentDefinition;setup(Lnet/minecraft/server/world/ServerWorld;)Vintermediary method_67051Lnet/minecraft/class_10665;method_67051(Lnet/minecraft/class_3218;)Vofficial aLtw;a(Laxg;)V
-
teardown
- Specified by:
teardownin interfaceTestEnvironmentDefinition- Mappings:
Namespace Name Mixin selector named teardownLnet/minecraft/test/TestEnvironmentDefinition;teardown(Lnet/minecraft/server/world/ServerWorld;)Vintermediary method_67054Lnet/minecraft/class_10665;method_67054(Lnet/minecraft/class_3218;)Vofficial bLtw;b(Laxg;)V
-
resetValue
- Mappings:
Namespace Name Mixin selector named resetValueLnet/minecraft/test/TestEnvironmentDefinition$GameRules;resetValue(Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/world/rule/GameRule;)Vintermediary method_76326Lnet/minecraft/class_10665$class_10668;method_76326(Lnet/minecraft/class_3218;Lnet/minecraft/class_12279;)Vofficial aLtw$c;a(Laxg;Lesi;)V
-
getCodec
- Specified by:
getCodecin interfaceTestEnvironmentDefinition- Mappings:
Namespace Name Mixin selector named getCodecLnet/minecraft/test/TestEnvironmentDefinition;getCodec()Lcom/mojang/serialization/MapCodec;intermediary method_67050Lnet/minecraft/class_10665;method_67050()Lcom/mojang/serialization/MapCodec;official aLtw;a()Lcom/mojang/serialization/MapCodec;
-
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 withObjects::equals(Object,Object). -
gameRulesMap
Returns the value of thegameRulesMaprecord component.- Returns:
- the value of the
gameRulesMaprecord component
-