Class Bank
- All Implemented Interfaces:
Serializable, Commented, ComprehensiveIdentification, Identified<Identification>, Named, Positioned<Place>, SimulationAgent, ChangeSource, Property, TaskProcessor
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:
-
Field Summary
Fields inherited from class SocialCollective
cohesion, leader, members -
Constructor Summary
ConstructorsConstructorDescriptionBank(String name, Identification identification, Set<EconomicAgent> owners, BusinessPlace place, Set<Account> accounts) Initializes a new Bank with official documentation.Minimal constructor for the modern API. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddClientAccount(Account account) Registers a new account with this bank.Returns unmodifiable set of client accounts.getConverted(Money amount, Currency target) Converts an amount from one currency to another.voidremoveClientAccount(Account account) Methods inherited from class Organization
addDepartment, addOwner, getCapital, getDepartments, getFoundedDate, getIndustry, getOrganigram, getOwners, getResources, getSector, getValue, setCapital, setIndustry, setResources, setSector, setValue, toStringMethods inherited from class Community
addResource, barterResources, consumeResources, removeResourceMethods inherited from class PsychologicalGroup
getFormalTerritory, getLeaders, getRelation, getRelations, setFormalTerritory, setLeaders, setRelation, setRelationMethods inherited from class Population
addMember, countAlive, countBySex, countByStage, equals, filter, getAgeDistribution, getAverageAge, getAverageFecundity, getFounders, getIndividuals, getLocation, getOldestAge, getPosition, getSexRatio, getSpecies, getTerritory, getYoungestAge, hashCode, processEvent, setIndividuals, setTerritory, sizeMethods inherited from class SocialCollective
getCohesion, getLeader, getMembers, removeMember, setCohesion, setLeaderMethods inherited from class SocialEntity
getEngine, getId, getInfluence, getPrestige, getSimId, getTraits, interact, setEngine, setInfluence, setPrestigeMethods inherited from interface ChangeSource
getExchangeRate, getExchangeRateValueMethods inherited from interface Commented
getComments, getTrait, setCommentsMethods inherited from interface ComprehensiveIdentification
getName, getTrait, setName, setTrait
-
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 nameidentification- legal tax/regulatory IDowners- set of ownersplace- physical headquartersaccounts- initial capital accounts
-
Bank
-
Bank
-
-
Method Details
-
getClientAccounts
-
addClientAccount
Registers a new account with this bank.- Parameters:
account- the account to add
-
removeClientAccount
-
getConverted
Description copied from interface:ChangeSourceConverts an amount from one currency to another.- Specified by:
getConvertedin interfaceChangeSource- Parameters:
amount- the amount to converttarget- the target currency- Returns:
- the converted amount in the target currency
-