
Chapter 25 Managing Persistent Component State
Persistence for entity components
An entity component is an EJB entity bean or a component of
another type that implements the CtsComponents::ObjectControl interface.
Entity components present an object view of relational data to clients;
each instance of an entity component maps to a row in a database
relation.
Component implementation requirements
Entity components can be EJB entity Beans implemented according
to the EJB 2.0, 1.1, or 1.0 standard (see Chapter 7, "Creating Enterprise JavaBeans Components"). You can also implement
CORBA entity components by following these requirements:
For an entity component, you can manage persistence using
these techniques:
- Component managed You implement the code that reads and writes persistent data
and maps the relational column values to fields in the implementation
class. This model corresponds to the Bean Managed Persistence (BMP)
model defined by the EJB 2.0 and 1.1 specifications, but has been
extended to support other component types.
- Automatic persistence EAServer generates skeleton code to manage the storage and
retrieval of persistent data. This model corresponds to the container-managed
Persistence (CMP) model defined by the EJB 2.0 and 1.1 specifications,
but has been extended to support other component types.
- Generated class A generated C++ or Java class saves and
restores component state from a remote database. EAServer (Jaguar
Manager) does not generate such classes, but third-party tool vendors
can use this option. The generated class can inherit from or delegate
to the component's implementation class to save and restore
component state.
Copyright © 2002 Sybase, Inc. All rights reserved.
|
|