Class Bank

All Implemented Interfaces:
Serializable, Commented, ComprehensiveIdentification, Identified<Identification>, Named, Positioned<Place>, SimulationAgent, ChangeSource, Property, TaskProcessor

public class Bank extends Organization implements ChangeSource
Represents a banking institution capable of managing accounts and providing currency conversion services. Extends Organization and implements ChangeSource. * @version 1.1
Since:
1.0
Author:
Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
See Also:
  • Constructor Details

    • Bank

      public Bank(String name, Identification identification, Set<EconomicAgent> owners, BusinessPlace place, Set<Account> accounts)
      Initializes a new Bank with official documentation.
      Parameters:
      name - official bank name
      identification - legal tax/regulatory ID
      owners - set of owners
      place - physical headquarters
      accounts - initial capital accounts
    • Bank

      public Bank(String name, Place place, Money initialCapital)
      Minimal constructor for the modern API.
    • Bank

      public Bank(String name)
  • Method Details

    • getClientAccounts

      public Set<Account> getClientAccounts()
      Returns unmodifiable set of client accounts.
    • addClientAccount

      public void addClientAccount(Account account)
      Registers a new account with this bank.
      Parameters:
      account - the account to add
    • removeClientAccount

      public void removeClientAccount(Account account)
    • getConverted

      public Money getConverted(Money amount, Currency target)
      Description copied from interface: ChangeSource
      Converts an amount from one currency to another.
      Specified by:
      getConverted in interface ChangeSource
      Parameters:
      amount - the amount to convert
      target - the target currency
      Returns:
      the converted amount in the target currency