Class ItemCache
- java.lang.Object
-
- org.rspeer.game.service.inventory.ItemCache
-
-
Constructor Summary
Constructors Constructor Description ItemCache(int capacity)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
contains(Function<ItemQuery,ItemQueryResults> function)
int
getCount(Function<ItemQuery,ItemQueryResults> function)
int
getCount(Function<ItemQuery,ItemQueryResults> function, boolean includeStacks)
int
getRemainingSlots()
int
getSlotCount()
int
getValidSlotCount()
List<Item>
getValidSlots()
boolean
isLoaded()
Iterator<Item>
iterator()
ItemQuery
query()
Stream<Item>
stream()
void
update(int slot, int id, int amount)
void
update(RSInventory inventory)
void
update(InventoryEvent event)
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Method Detail
-
update
public void update(InventoryEvent event)
-
update
public void update(RSInventory inventory)
-
update
public void update(int slot, int id, int amount)
-
getValidSlotCount
public int getValidSlotCount()
-
getRemainingSlots
public int getRemainingSlots()
-
getSlotCount
public int getSlotCount()
-
contains
public boolean contains(Function<ItemQuery,ItemQueryResults> function)
-
getCount
public int getCount(Function<ItemQuery,ItemQueryResults> function)
-
getCount
public int getCount(Function<ItemQuery,ItemQueryResults> function, boolean includeStacks)
-
isLoaded
public boolean isLoaded()
-
query
public ItemQuery query()
-
-