Factories That Produce Persistence Managers
The persistenceManager is is both the principal service interface of JDO and the gateway to its other service interfaces. To obtain objects that implement the PersistenceManager interface, the application uses the PersistenceManagerFactory interface. In some cases, the application can obtain a PersistenceManager from a javax. resource. cci.ConnectionFactory interface, which is defined in the J2EE Connector Architecture (JCA). Since both the PersistenceManagerFactory and the ConnectionFactory are interfaces, how does the application obtain the object that implements one of these interfaces? As it turns out, the answer is nearly trivial. If all this chapter had to do was explain how to get a factory, it would be quite short.
Unable to display preview. Download preview PDF.