Package org.geysermc.geyser.inventory
Record Class BedrockContainerSlot
java.lang.Object
java.lang.Record
org.geysermc.geyser.inventory.BedrockContainerSlot
public record BedrockContainerSlot(org.cloudburstmc.protocol.bedrock.data.inventory.ContainerSlotType container, int slot)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionBedrockContainerSlot(org.cloudburstmc.protocol.bedrock.data.inventory.ContainerSlotType container, int slot) Creates an instance of aBedrockContainerSlotrecord class. -
Method Summary
Modifier and TypeMethodDescriptionorg.cloudburstmc.protocol.bedrock.data.inventory.ContainerSlotTypeReturns the value of thecontainerrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intslot()Returns the value of theslotrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
BedrockContainerSlot
public BedrockContainerSlot(org.cloudburstmc.protocol.bedrock.data.inventory.ContainerSlotType container, int slot) Creates an instance of aBedrockContainerSlotrecord class.- Parameters:
container- the value for thecontainerrecord componentslot- the value for theslotrecord 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 '=='. -
container
public org.cloudburstmc.protocol.bedrock.data.inventory.ContainerSlotType container()Returns the value of thecontainerrecord component.- Returns:
- the value of the
containerrecord component
-
slot
public int slot()Returns the value of theslotrecord component.- Returns:
- the value of the
slotrecord component
-