Record Class InventoryType.DefaultItemComponentLookup
java.lang.Object
java.lang.Record
org.rspeer.game.component.InventoryType.DefaultItemComponentLookup
- All Implemented Interfaces:
InventoryType.ItemComponentLookup
- Enclosing class:
InventoryType
public static record InventoryType.DefaultItemComponentLookup(boolean checkVisibility, int[] ids)
extends Record
implements InventoryType.ItemComponentLookup
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultItemComponentLookup(boolean checkVisibility, int... ids) Creates an instance of aDefaultItemComponentLookuprecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of thecheckVisibilityrecord component.final booleanIndicates whether some other object is "equal to" this one.find()final inthashCode()Returns a hash code value for this object.int[]ids()Returns the value of theidsrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from interface InventoryType.ItemComponentLookup
first
-
Constructor Details
-
DefaultItemComponentLookup
public DefaultItemComponentLookup(boolean checkVisibility, int... ids) Creates an instance of aDefaultItemComponentLookuprecord class.- Parameters:
checkVisibility- the value for thecheckVisibilityrecord componentids- the value for theidsrecord component
-
-
Method Details
-
find
- Specified by:
findin interfaceInventoryType.ItemComponentLookup
-
toString
-
hashCode
-
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 thecomparemethod from their corresponding wrapper classes. -
checkVisibility
public boolean checkVisibility()Returns the value of thecheckVisibilityrecord component.- Returns:
- the value of the
checkVisibilityrecord component
-
ids
public int[] ids()Returns the value of theidsrecord component.- Returns:
- the value of the
idsrecord component
-