Interface InventorySize
- All Known Implementing Classes:
BukkitInventorySize
,MinestomInventorySize
public interface InventorySize
The size of the inventory
-
Method Summary
Modifier and TypeMethodDescriptionint
getSize()
Get the size of the inventorydefault int
Get the slot per rowdefault IntStream
getSlots()
Get the slotsdefault InventoryPosition
toPosition
(int slot) Convert the slot to the positiondefault IntStream
toSlots
(Stream<InventoryPosition> positions) Convert the position to the slot
-
Method Details
-
getSize
int getSize()Get the size of the inventory- Returns:
- the size
-
getSlotPerRow
default int getSlotPerRow()Get the slot per row- Returns:
- the slot per row
-
getSlots
Get the slots- Returns:
- the slots
-
toPosition
Convert the slot to the position- Parameters:
slot
- the slot- Returns:
- the position
-
toSlots
Convert the position to the slot- Parameters:
positions
- the positions- Returns:
- the slots
-