java.lang.Object
net.botwithus.rs3.game.inventories.InventoryContainer
-
Method Summary
Modifier and TypeMethodDescriptionboolean
contains
(int id) Check if the InventoryContainer contains a specific itemboolean
contains
(int id, int amount) boolean
contains
(int id, int value, com.google.common.collect.Maps.EntryTransformer<Integer, Integer, Boolean> predicate) boolean
Check if the InventoryContainer contains a specific itemboolean
boolean
Check if the InventoryContainer contains a specific itemboolean
containsCategories
(int... categories) Check if the InventoryContainer contains a specific categoryboolean
containsCategory
(int category) Check if the InventoryContainer contains a specific categoryint
getId()
Get the id of the InventoryContainergetItems()
boolean
isEmpty()
boolean
isFull()
boolean
static InventoryContainer
of
(int id) Create a new InventoryContainerstatic InventoryContainer
of
(int id, InventoryItemQuery query) Create a new InventoryContainer with an additional queryslot
(int slot)
-
Method Details
-
getId
public int getId()Get the id of the InventoryContainer- Returns:
- the id of the InventoryContainer
-
isEmpty
public boolean isEmpty() -
isNotEmpty
public boolean isNotEmpty() -
contains
public boolean contains(int id) Check if the InventoryContainer contains a specific item- Parameters:
id
- the ids of the items to check for- Returns:
- true if the InventoryContainer contains the item
-
contains
-
contains
public boolean contains(int id, int amount) -
contains
-
slot
-
contains
Check if the InventoryContainer contains a specific item- Parameters:
names
- the names of the items to check for- Returns:
- true if the InventoryContainer contains the item
-
contains
Check if the InventoryContainer contains a specific item- Parameters:
pattern
- the pattern to check for- Returns:
- true if the InventoryContainer contains the item
-
isFull
public boolean isFull() -
containsCategory
public boolean containsCategory(int category) Check if the InventoryContainer contains a specific category- Parameters:
category
- the category to check for- Returns:
- true if the InventoryContainer contains the category
-
containsCategories
public boolean containsCategories(int... categories) Check if the InventoryContainer contains a specific category- Parameters:
categories
- the categories to check for- Returns:
- true if the InventoryContainer contains the category
-
getItems
-
of
Create a new InventoryContainer- Parameters:
id
- the id of the container- Returns:
- a new InventoryContainer
-
of
Create a new InventoryContainer with an additional query- Parameters:
id
- the id of the containerquery
- the additional query- Returns:
- a new InventoryContainer with the additional query
-