Record Class GameTestData
java.lang.Object
java.lang.Record
net.neoforged.testframework.gametest.GameTestData
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final @Nullable StringThe field for thebatchNamerecord component.private final Consumer<GameTestHelper> The field for thefunctionrecord component.private final intThe field for themaxAttemptsrecord component.private final intThe field for themaxTicksrecord component.private final booleanThe field for therequiredrecord component.private final intThe field for therequiredSuccessesrecord component.private final RotationThe field for therotationrecord component.private final longThe field for thesetupTicksrecord component.private final booleanThe field for theskyAccessrecord component.private final StringThe field for thestructureNamerecord component. -
Constructor Summary
ConstructorsConstructorDescriptionGameTestData(@Nullable String batchName, String structureName, boolean required, int maxAttempts, int requiredSuccesses, Consumer<GameTestHelper> function, int maxTicks, long setupTicks, Rotation rotation, boolean skyAccess) Creates an instance of aGameTestDatarecord class. -
Method Summary
Modifier and TypeMethodDescription@Nullable StringReturns the value of thebatchNamerecord component.final booleanIndicates whether some other object is "equal to" this one.function()Returns the value of thefunctionrecord component.final inthashCode()Returns a hash code value for this object.intReturns the value of themaxAttemptsrecord component.intmaxTicks()Returns the value of themaxTicksrecord component.booleanrequired()Returns the value of therequiredrecord component.intReturns the value of therequiredSuccessesrecord component.rotation()Returns the value of therotationrecord component.longReturns the value of thesetupTicksrecord component.booleanReturns the value of theskyAccessrecord component.Returns the value of thestructureNamerecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
batchName
The field for thebatchNamerecord component. -
structureName
The field for thestructureNamerecord component. -
required
private final boolean requiredThe field for therequiredrecord component. -
maxAttempts
private final int maxAttemptsThe field for themaxAttemptsrecord component. -
requiredSuccesses
private final int requiredSuccessesThe field for therequiredSuccessesrecord component. -
function
The field for thefunctionrecord component. -
maxTicks
private final int maxTicksThe field for themaxTicksrecord component. -
setupTicks
private final long setupTicksThe field for thesetupTicksrecord component. -
rotation
The field for therotationrecord component. -
skyAccess
private final boolean skyAccessThe field for theskyAccessrecord component.
-
-
Constructor Details
-
GameTestData
public GameTestData(@Nullable @Nullable String batchName, String structureName, boolean required, int maxAttempts, int requiredSuccesses, Consumer<GameTestHelper> function, int maxTicks, long setupTicks, Rotation rotation, boolean skyAccess) Creates an instance of aGameTestDatarecord class.- Parameters:
batchName- the value for thebatchNamerecord componentstructureName- the value for thestructureNamerecord componentrequired- the value for therequiredrecord componentmaxAttempts- the value for themaxAttemptsrecord componentrequiredSuccesses- the value for therequiredSuccessesrecord componentfunction- the value for thefunctionrecord componentmaxTicks- the value for themaxTicksrecord componentsetupTicks- the value for thesetupTicksrecord componentrotation- the value for therotationrecord componentskyAccess- the value for theskyAccessrecord component
-
-
Method Details
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
batchName
Returns the value of thebatchNamerecord component.- Returns:
- the value of the
batchNamerecord component
-
structureName
Returns the value of thestructureNamerecord component.- Returns:
- the value of the
structureNamerecord component
-
required
public boolean required()Returns the value of therequiredrecord component.- Returns:
- the value of the
requiredrecord component
-
maxAttempts
public int maxAttempts()Returns the value of themaxAttemptsrecord component.- Returns:
- the value of the
maxAttemptsrecord component
-
requiredSuccesses
public int requiredSuccesses()Returns the value of therequiredSuccessesrecord component.- Returns:
- the value of the
requiredSuccessesrecord component
-
function
Returns the value of thefunctionrecord component.- Returns:
- the value of the
functionrecord component
-
maxTicks
public int maxTicks()Returns the value of themaxTicksrecord component.- Returns:
- the value of the
maxTicksrecord component
-
setupTicks
public long setupTicks()Returns the value of thesetupTicksrecord component.- Returns:
- the value of the
setupTicksrecord component
-
rotation
Returns the value of therotationrecord component.- Returns:
- the value of the
rotationrecord component
-
skyAccess
public boolean skyAccess()Returns the value of theskyAccessrecord component.- Returns:
- the value of the
skyAccessrecord component
-