Package com.jtprince.coordinateoffset
Record Class OffsetData.Source.SetCommand
java.lang.Object
java.lang.Record
com.jtprince.coordinateoffset.OffsetData.Source.SetCommand
- All Implemented Interfaces:
OffsetData.Source
- Enclosing interface:
OffsetData.Source
public static record OffsetData.Source.SetCommand(OffsetSetCommand command, @Nullable OffsetProvider affectedProvider)
extends Record
implements OffsetData.Source
This offset was explicitly set by a command.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.jtprince.coordinateoffset.OffsetData.Source
OffsetData.Source.BedrockBypass, OffsetData.Source.PermissionBypass, OffsetData.Source.PluginSet, OffsetData.Source.Provider, OffsetData.Source.SetCommand -
Constructor Summary
ConstructorsConstructorDescriptionSetCommand(OffsetSetCommand command, @Nullable OffsetProvider affectedProvider) Creates an instance of aSetCommandrecord class. -
Method Summary
Modifier and TypeMethodDescription@Nullable OffsetProviderReturns the value of theaffectedProviderrecord component.command()Returns the value of thecommandrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SetCommand
Creates an instance of aSetCommandrecord class.- Parameters:
command- the value for thecommandrecord componentaffectedProvider- the value for theaffectedProviderrecord 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. All components in this record class are compared withObjects::equals(Object,Object). -
command
Returns the value of thecommandrecord component.- Returns:
- the value of the
commandrecord component
-
affectedProvider
Returns the value of theaffectedProviderrecord component.- Returns:
- the value of the
affectedProviderrecord component
-