|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface BankService
Defines the interface of the bank service.
| Field Summary |
|---|
| Fields inherited from interface net.coalevo.foundation.model.Maintainable |
|---|
DO_MAINTENANCE |
| Method Summary | |
|---|---|
void |
closeAccount(Agent caller,
AgentIdentifier aid)
Closes an existing Account. |
void |
deposit(Agent caller,
AgentIdentifier to,
long sum)
Deposits a specific sum to a specified account. |
boolean |
existsAccount(Agent caller,
AgentIdentifier aid)
Tests if there is an Account bound to a specified agent. |
long |
getAccountBalance(Agent caller,
AgentIdentifier aid)
Returns the account balance for an existing Account. |
AccountStats |
getAccountStats(Agent caller)
Returns summary AccountStats for all Account
instances. |
void |
openAccount(Agent caller,
AgentIdentifier aid)
Opens a new Account bound to a specified agent. |
long |
retrieve(Agent caller,
AgentIdentifier to,
long sum)
Retrieves the specified sum from the given account. |
long |
transfer(Agent caller,
AgentIdentifier from,
AgentIdentifier to,
long sum)
Transfer between two accounts. |
| Methods inherited from interface net.coalevo.foundation.model.Service |
|---|
activate, deactivate, getActions |
| Methods inherited from interface net.coalevo.foundation.model.Identifiable |
|---|
getIdentifier |
| Methods inherited from interface net.coalevo.foundation.model.Maintainable |
|---|
doMaintenance |
| Method Detail |
|---|
boolean existsAccount(Agent caller,
AgentIdentifier aid)
throws java.lang.SecurityException,
BankServiceException
Account bound to a specified agent.
caller - the requesting Agent.aid - the identifier of the agent the new account should be bound to.
java.lang.SecurityException - if the calling Agent is not authentic or
not authorized.
BankServiceException - if an error occurs while executing this action.
void openAccount(Agent caller,
AgentIdentifier aid)
throws java.lang.SecurityException,
BankServiceException
Account bound to a specified agent.
caller - the requesting Agent.aid - the identifier of the agent the new account should be bound to.
java.lang.SecurityException - if the calling Agent is not authentic or
not authorized.
BankServiceException - if an error occurs while executing this action.
void closeAccount(Agent caller,
AgentIdentifier aid)
throws java.lang.SecurityException,
BankServiceException
Account.
caller - the requesting Agent.aid - the identifier of the agent the new account is bound to.
java.lang.SecurityException - if the calling Agent is not authentic or
not authorized.
BankServiceException - if an error occurs while executing this action.
long getAccountBalance(Agent caller,
AgentIdentifier aid)
throws java.lang.SecurityException,
BankServiceException
Account.
caller - the requesting Agent.aid - the identifier of the agent the new account is bound to.
java.lang.SecurityException - if the calling Agent is not authentic or
not authorized.
BankServiceException - if an error occurs while executing this action.
long transfer(Agent caller,
AgentIdentifier from,
AgentIdentifier to,
long sum)
throws java.lang.SecurityException,
BankServiceException
caller - the requesting Agent.from - the identifier of the agent the paying account is bound to.to - the identifier of the agent the receiving account is bound to.sum - the sum to be transferred.
java.lang.SecurityException - if the calling Agent is not authentic or
not authorized.
BankServiceException - if an error occurs while executing this action.
void deposit(Agent caller,
AgentIdentifier to,
long sum)
throws java.lang.SecurityException,
BankServiceException
caller - the requesting Agent.to - the identifier of the agent the receiving account is bound to.sum - the sum to be awarded.
java.lang.SecurityException - if the calling Agent is not authentic or
not authorized.
BankServiceException - if an error occurs while executing this action.
long retrieve(Agent caller,
AgentIdentifier to,
long sum)
throws java.lang.SecurityException,
BankServiceException
caller - the requesting Agent.to - the identifier of the agent the receiving account is bound to.sum - the sum to be awarded.
java.lang.SecurityException - if the calling Agent is not authentic or
not authorized.
BankServiceException - if an error occurs while executing this action.
AccountStats getAccountStats(Agent caller)
throws java.lang.SecurityException,
BankServiceException
AccountStats for all Account
instances.
caller - the requesting Agent.
java.lang.SecurityException - if the calling Agent is not authentic or
not authorized.
BankServiceException - if an error occurs while executing this action.
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||