Interface EquipmentSlot
- All Superinterfaces:
FilteringSlot
,Inventory
,Slot
,ValueContainer
An inventory slot which can only contain equipment.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.spongepowered.api.item.inventory.Inventory
Inventory.Builder
-
Method Summary
Modifier and TypeMethodDescriptionboolean
isValidItem
(EquipmentType type) Check whether the supplied equipment type can be inserted into this slot.Methods inherited from interface org.spongepowered.api.item.inventory.slot.FilteringSlot
isValidItem, isValidItem
Methods inherited from interface org.spongepowered.api.item.inventory.Inventory
asViewable, canFit, capacity, children, clear, contains, contains, containsAny, containsChild, containsInventory, freeCapacity, get, get, hasChildren, intersect, offer, offer, parent, peek, peekAt, poll, poll, pollFrom, pollFrom, query, query, query, query, query, query, root, set, slot, slots, totalQuantity, union
Methods inherited from interface org.spongepowered.api.item.inventory.Slot
set, viewedSlot
-
Method Details
-
isValidItem
Check whether the supplied equipment type can be inserted into this slot. Returning false from this method implies thatInventory.offer(org.spongepowered.api.item.inventory.ItemStack...)
would always return false for items of this type.- Parameters:
type
- EquipmentType to check- Returns:
- true if the specified EquipmentType is valid for this slot
-