Our development library contains the classes necessary to implement our custom DAO framework and Struts dispatching model. This library is available in .jar format and can be used to integrate basicPortal technology into your existing web application.
basicPortal's "No Copy" Design
basicPortal uses a "no copy" open source implementation of the Sun disconnected rowset in it's DAO layer. What this means to the developer is that performance is built in and garbage collection is low.
As apposed to other persistance mechanisms that copy values from object to object and have large garbage collection needs, bP's "no copy" feature is designed to be fast and efficient.
The basicPortal persistance mechanism
basicDAOWebLib includes a custom DAO layer (Data Access Object). Sun describes the DAO layer as follows:
Code that depends on specific features of data resources ties together business logic with data access logic. This makes it difficult to replace or modify an application's data resources.
The Data Access Object (or DAO) pattern:
- separates a data resource's client interface from its data access mechanisms
- adapts a specific data resource's access API to a generic client interface
- The DAO pattern allows data access mechanisms to change independently of the code that uses the data.
The DAO layer used by BasicPortal enables developers to write Struts applications without having to code database access logic every time they need data. Using our DAO layer, the developer codes a Bean class and a DAO class for each set of data he needs to access. A set of data is defined with a valid SQL query. It can be a simple "select * from mytable" or a complicated join.
The Bean class delegates it's work to the DAO class. The basicportal DAO classes use a disconnected rowset under the hood to do the select, insert and updates (see jxUtil). Once the DAO is coded the developer uses the Bean class to interact with the DAO direct access to the DAO is not needed. The developer calls the bean methods and the Bean accesses the DAO internally. This model of itneracting with the Bean and not the DAO greatly simplifies a developers life.
The Bean Classes that a developer creates all inherit from a base class that extends Collection. The fact that each Bean is a Collection provides many benefits to the developer when coding in Struts. JSP interaction with a bean is very simple and Struts handles calling all update methods.
Any questions on BasicPortal and the DAO layer can be addressed to the MVC progammers list at: email@example.com