|
OpMath | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--com.opmath.test.j2ee.contact.ContactBean
The business logic for the contact component. In fact, this class does not perform any sort of transformation on its data - it is simply concerned with storing and retrieving the contact record data according to transactional rules. This EJB also has a unique key, which is used by the container as a primary key.
Copyright: (c) 2002 The Open Math Company Limited
The Terms of Distribution of this software are stipulated in the javadoc Overview for this project.
| Constructor Summary | |
ContactBean()
|
|
| Method Summary | |
void |
ejbActivate()
Invoked when the instance is taken out of the pool of available instances to become associated with a specific EJB object. |
ContactPK |
ejbCreate(ContactPK key,
ContactVO data)
Creates a new Contact EJB instance. |
void |
ejbLoad()
The container invokes this method to instruct the instance to synchronize its state by loading its state from the underlying database. |
void |
ejbPassivate()
A container invokes this method on an instance before the instance becomes disassociated with a specific EJB object. |
void |
ejbPostCreate(ContactPK key,
ContactVO data)
Executed after the create operation has completed. |
void |
ejbRemove()
The container invokes this method before it removes the EJB object that is currently associated with the instance. |
void |
ejbStore()
The container invokes this method to instruct the instance to synchronize its state by storing it to the underlying database. |
ContactVO |
getData()
Returns the value object for this Contact EJB. |
abstract String |
getEmail()
Returns the 'email' field for this Contact EJB. |
abstract String |
getFamilyName()
Returns the 'family name' field for this Contact EJB. |
abstract String |
getGivenName()
Returns the 'given name' field for this Contact EJB. |
abstract ContactPK |
getKey()
Returns the primary key for this Contact EJB. |
abstract String |
getPhone()
Returns the 'phone' field for this Contact EJB. |
void |
setData(ContactVO data)
Sets the state for this Contact EJB, according to the given ContactVO object. |
abstract void |
setEmail(String email)
Sets the 'email' field for this Contact EJB, to the given String. |
void |
setEntityContext(EntityContext ctx)
Sets the private entity context of this instance. |
abstract void |
setFamilyName(String familyName)
Sets the 'family name' field for this Contact EJB, to the given String. |
abstract void |
setGivenName(String givenName)
Sets the 'given name' field for this Contact EJB, to the given String. |
abstract void |
setKey(ContactPK key)
Sets the primary key for this Contact EJB to the given ContactPK object. |
abstract void |
setPhone(String phone)
Sets the 'phone' field for this Contact EJB, to the given String. |
void |
unsetEntityContext()
Sets the private entity context of this instance to null. |
| Methods inherited from class java.lang.Object |
|
| Constructor Detail |
public ContactBean()
| Method Detail |
public abstract ContactPK getKey()
Returns the primary key for this Contact EJB.
This method is implemented by the EJB 2.0 compliant container.
ContactPK uniquely identifying this Contact EJB instance.public abstract void setKey(ContactPK key)
Sets the primary key for this Contact EJB to the given
ContactPK object. Note that this method should not
be made available via the EJB's remote interface.
This method is implemented by the EJB 2.0 compliant container.
key - a UniqueIdGeneratorPK specifying the key.public abstract String getGivenName()
Returns the 'given name' field for this Contact EJB. Note that this method should not be made available via the EJB's remote interface - instead, a value object should be used to expose the complete EJB state.
This method is implemented by the EJB 2.0 compliant container.
String carrying the 'given name' field.public abstract void setGivenName(String givenName)
Sets the 'given name' field for this Contact EJB, to the given
String. Note that this method should not be made available
via the EJB's remote interface - instead, a value object should be used to
expose the complete EJB state.
This method is implemented by the EJB 2.0 compliant container.
givenName - a String specifying the
'given name' field.public abstract String getFamilyName()
Returns the 'family name' field for this Contact EJB. Note that this method should not be made available via the EJB's remote interface - instead, a value object should be used to expose the complete EJB state.
This method is implemented by the EJB 2.0 compliant container.
String carrying the 'family name' field.public abstract void setFamilyName(String familyName)
Sets the 'family name' field for this Contact EJB, to the given
String. Note that this method should not be made available
via the EJB's remote interface - instead, a value object should be used to
expose the complete EJB state.
This method is implemented by the EJB 2.0 compliant container.
familyName - a String specifying the
'family name' field.public abstract String getEmail()
Returns the 'email' field for this Contact EJB. Note that this method should not be made available via the EJB's remote interface - instead, a value object should be used to expose the complete EJB state.
This method is implemented by the EJB 2.0 compliant container.
String carrying the 'email' field.public abstract void setEmail(String email)
Sets the 'email' field for this Contact EJB, to the given
String. Note that this method should not be made available
via the EJB's remote interface - instead, a value object should be used to
expose the complete EJB state.
This method is implemented by the EJB 2.0 compliant container.
email - a String specifying the
'email' field.public abstract String getPhone()
Returns the 'phone' field for this Contact EJB. Note that this method should not be made available via the EJB's remote interface - instead, a value object should be used to expose the complete EJB state.
This method is implemented by the EJB 2.0 compliant container.
String carrying the 'phone' field.public abstract void setPhone(String phone)
Sets the 'phone' field for this Contact EJB, to the given
String. Note that this method should not be made available
via the EJB's remote interface - instead, a value object should be used to
expose the complete EJB state.
This method is implemented by the EJB 2.0 compliant container.
phone - a String specifying the
'phone' field.public ContactVO getData()
Returns the value object for this Contact EJB.
ContactVO carrying the state of this Contact EJB.public void setData(ContactVO data)
Sets the state for this Contact EJB, according to the given
ContactVO object.
data - a ContactVO specifying the
state of this Contact EJB.
public ContactPK ejbCreate(ContactPK key,
ContactVO data)
throws CreateException
Creates a new Contact EJB instance. The new instance will have the given key and state.
key - a ContactPK specifying the key.data - a ContactVO specifying the state.ContactPK uniquely identifying this Contact EJB instance.CreateException - if the new instance could not be created,
for whatever reason.
public void ejbPostCreate(ContactPK key,
ContactVO data)
throws CreateException
Executed after the create operation has completed. Does nothing.
key - a ContactPK specifying the key.data - a ContactVO specifying the state.CreateException - if the method not be executed,
for whatever reason (for example, because a UniqueIdGenerator
with the same key already exists).public void setEntityContext(EntityContext ctx)
Sets the private entity context of this instance. The container invokes this method on
an instance before ejbCreate(ContactPK, ContactVO).
setEntityContext in interface EntityBeanctx - an EntityContext.public void unsetEntityContext()
Sets the private entity context of this instance to null.
The container calls this method before removing the instance.
unsetEntityContext in interface EntityBeanpublic void ejbLoad()
The container invokes this method to instruct the instance to synchronize its state by loading its state from the underlying database. Does nothing.
ejbLoad in interface EntityBeanpublic void ejbStore()
The container invokes this method to instruct the instance to synchronize its state by storing it to the underlying database. Does nothing.
ejbStore in interface EntityBeanpublic void ejbActivate()
Invoked when the instance is taken out of the pool of available instances to become associated with a specific EJB object.
This transitions the instance to the ready state.
ejbActivate in interface EntityBeanpublic void ejbPassivate()
A container invokes this method on an instance before the instance becomes disassociated with a specific EJB object.
After this method completes, the container will place the instance into the pool of available instances.
ejbPassivate in interface EntityBeanpublic void ejbRemove()
The container invokes this method before it removes the EJB object that is currently associated with the instance.
This transitions the instance from the ready state to the pool of available instances.
ejbRemove in interface EntityBean
|
OpMath | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||