The Cash Drawer Management manages the creation, update and deletion of a Cash Drawer and also maintains the counters for the total amounts, counts, and so on.
The following diagram shows the main components in Cash Drawer Management:
CDM Service is the Business component for Cash Drawer Management. It implements all the use cases and handles most of the situations in banking teller system. It is implemented in POJO. You can have different options to deploy it, for example, you can deploy it as an EJB or a WebService according to the deployment requirement.
Business Delegation is a proxy for CDM Service in the client side. It handles the details of the remote invocation from the client side.
User Interface is for the teller to operate on the Cash Drawer. The User Interface is based on Rich Client.
DataModel models the Cash Drawer. It is the representation of the physical Cash Drawer in the computer memory.
Rules Provider allows you to define the rule how the Cash Drawer Manager updates the DataModel. By default, BTT provides a basic implementation for the Rules Provider. It accepts the definitions from the XML file.
DAO is a set of interfaces that know how to synchronize DataModel with persistent storage, such as database or file. There will be two types of implementation at the development phase to simplify the environment setup. And the deployer chooses the database implementation to meet the requirement of the persisting DataModel in the database.
Cash Drawer Manager knows how to process the business logic of the component, and it updates the DataModel through DAO interface according to the defined rules, and it calls the PostProcessor each time on the update.
ElementFactory is the IOC (Inversion of Control) container in BTT. It reads the configuration in XML file and assembles all the components from pieces to a whole. It also provides some capabilities of AOP. It makes the CDM service become flexible.
XML is the configuration for the CDM Service. It complies with the contract of ElementFactory. It defines how the components in CDM services are assembled together. For example, it defines which DAO implementation to use, which PostProcessor implementation to use and which RulesProvider implementation to use. You can edit the XML file.