Interface IBank

All Superinterfaces:
IItems<IBankItem>, ItemProvider<IBankItem>

public interface IBank extends IItems<IBankItem>
Provides access to the bank interface and operations.

The bank stores items with up to 816 slots organized in tabs. This interface provides methods for:

  • Opening and closing the bank
  • Depositing items from inventory and equipment
  • Withdrawing items (normal or noted)
  • Managing bank tabs
  • Querying bank contents

Example usage:

 
 IBank bank = Static.getBank();
 bank.open(BankLocation.GRAND_EXCHANGE);
 bank.depositInventory();
 bank.withdraw("Lobster", 10);
 bank.close();
 
 

See Also:
  • Method Details

    • isOpen

      boolean isOpen()
      Checks if the bank interface is currently open.
      Returns:
      true if the bank is open, false otherwise
    • open

      void open(net.runelite.api.coords.WorldArea area)
      Opens the nearest bank in the specified area.

      This will path to the area and interact with a bank object.

      Parameters:
      area - the area containing a bank
    • open

      void open(BankLocation bankLocation)
      Opens the bank at a specific predefined location.

      This will path to the location and interact with the bank.

      Parameters:
      bankLocation - the bank location
    • close

      void close()
      Closes the bank interface.
    • isMainTabOpen

      boolean isMainTabOpen()
      Checks if the main bank tab is currently open.
      Returns:
      true if the main tab is open, false otherwise
    • isTabOpen

      boolean isTabOpen(int index)
      Checks if a specific bank tab is currently open.
      Parameters:
      index - the tab index (0-9)
      Returns:
      true if the tab is open, false otherwise
    • openMainTab

      void openMainTab()
      Opens the main bank tab (all items).
    • openTab

      void openTab(int index)
      Opens a specific bank tab.
      Parameters:
      index - the tab index (0-9)
    • getTabs

      List<IWidget> getTabs()
      Gets all bank tab widgets.
      Returns:
      list of bank tab widgets
    • setWithdrawMode

      void setWithdrawMode(boolean noted)
      Sets the withdraw mode for the bank.
      Parameters:
      noted - true to withdraw as noted items, false for normal items
    • isNotedWithdrawMode

      boolean isNotedWithdrawMode()
      Checks if the bank is in noted withdraw mode.
      Returns:
      true if withdrawing noted items, false otherwise
    • depositInventory

      void depositInventory()
      Deposits all items from the inventory into the bank.
    • depositEquipment

      void depositEquipment()
      Deposits all equipped items into the bank.
    • emptyContainers

      void emptyContainers()
      Empties containers into the bank.
    • withdraw

      void withdraw(Predicate<IItem> filter, int amount, WithdrawMode withdrawMode, boolean quick)
      Withdraws items from the bank matching a filter.

      This is the core withdraw method with full control over options.

      Parameters:
      filter - the filter to match items
      amount - the amount to withdraw (use Integer.MAX_VALUE for all)
      withdrawMode - the withdraw mode (normal, noted, or default)
      quick - true to use quick-withdraw, false for menu interaction
    • deposit

      void deposit(Predicate<? super IItem> filter, int amount, boolean quick)
      Deposits items from the inventory matching a filter.

      This is the core deposit method with full control over options.

      Parameters:
      filter - the filter to match items
      amount - the amount to deposit (use Integer.MAX_VALUE for all)
      quick - true to use quick-deposit, false for menu interaction
    • depositAll

      default void depositAll(String... names)
    • depositAll

      default void depositAll(int... ids)
    • depositAll

      default void depositAll(Predicate<? super IItem> filter)
    • depositAllExcept

      default void depositAllExcept(String... names)
    • depositAllExcept

      default void depositAllExcept(int... ids)
    • depositAllExcept

      default void depositAllExcept(Predicate<? super IItem> filter)
    • withdrawAll

      default void withdrawAll(String name)
    • withdrawAll

      default void withdrawAll(String name, WithdrawMode withdrawMode)
    • withdrawAll

      default void withdrawAll(int id)
    • withdrawAll

      default void withdrawAll(int id, WithdrawMode withdrawMode)
    • withdrawAll

      default void withdrawAll(Predicate<IItem> filter)
    • withdrawAll

      default void withdrawAll(Predicate<IItem> filter, WithdrawMode withdrawMode)
    • withdraw

      default void withdraw(String name, int amount, boolean quick)
    • withdraw

      default void withdraw(String name, int amount)
    • withdraw

      default void withdraw(String name, int amount, WithdrawMode withdrawMode, boolean quick)
    • withdraw

      default void withdraw(String name, int amount, WithdrawMode withdrawMode)
    • withdraw

      default void withdraw(int id, int amount, boolean quick)
    • withdraw

      default void withdraw(int id, int amount)
    • withdraw

      default void withdraw(int id, int amount, WithdrawMode withdrawMode, boolean quick)
    • withdraw

      default void withdraw(int id, int amount, WithdrawMode withdrawMode)
    • withdraw

      default void withdraw(Predicate<IItem> filter, int amount, boolean quick)
    • withdraw

      default void withdraw(Predicate<IItem> filter, int amount)
    • withdraw

      default void withdraw(Predicate<IItem> filter, int amount, WithdrawMode withdrawMode)
    • deposit

      default void deposit(String name, int amount, boolean quick)
    • deposit

      default void deposit(int id, int amount, boolean quick)
    • deposit

      default void deposit(String name, int amount)
    • deposit

      default void deposit(int id, int amount)
    • deposit

      default void deposit(Predicate<? super IItem> filter, int amount)