jrun.ejb
Class CMP20EntityContainer
jrunx.kernel.ServiceAdapter
|
+--jrunx.kernel.ServicePartition
|
+--jrunx.kernel.ConfigurableServicePartition
|
+--jrun.j2ee.J2EEModule
|
+--jrun.ejb.Container
|
+--jrun.ejb.EJBContainer
|
+--jrun.ejb.ClientInvokableContainer
|
+--jrun.ejb.EntityContainer
|
+--jrun.ejb.CMP20EntityContainer
- All Implemented Interfaces:
- ConfigurableServicePartitionMBean, ContainerMBean, EJBContainerMBean, J2EEModuleMBean, javax.naming.Referenceable, java.io.Serializable, Service, ServiceMBean, ServicePartitionMBean
- public class CMP20EntityContainer
- extends EntityContainer
The CMP 2.0 Entity EJB container subclass.
- Author:
- Paul Reilly
- See Also:
- Serialized Form
| Fields inherited from class jrunx.kernel.ServiceAdapter |
DEFAULT_DEACTIVATED, DEFAULT_DOMAIN, DOMAIN_NAME_SEPARATOR, DOMAIN_NAME_SUFFIX, domainName, jndiBindable, LOGGER_CACHE_TIME, SCHEDULER_SERVICE, SECURITY_MANAGER, server, status, TRANSACTION_MANAGER |
|
Method Summary |
void |
collectionAdd(EJBInvocation ejbInvocation)
|
void |
collectionAddAll(EJBInvocation ejbInvocation)
|
void |
collectionClear(EJBInvocation ejbInvocation)
|
boolean |
collectionContains(EJBInvocation ejbInvocation)
|
boolean |
collectionContainsAll(EJBInvocation ejbInvocation)
|
boolean |
collectionIsEmpty(EJBInvocation ejbInvocation)
|
java.util.Iterator |
collectionIterator(EJBInvocation ejbInvocation)
|
void |
collectionRemove(EJBInvocation ejbInvocation)
|
void |
collectionRemoveAll(EJBInvocation ejbInvocation)
|
void |
collectionRetainAll(EJBInvocation ejbInvocation)
|
int |
collectionSize(EJBInvocation ejbInvocation)
|
java.lang.Object[] |
collectionToArray(EJBInvocation ejbInvocation)
|
java.util.Collection |
findRelatedEntities(java.lang.String fieldName,
java.lang.String ejbName,
EntityInstance entityInstance)
This is public, because it is used by the code generated
abstract entity bean implementations, in the CMR getters. |
java.lang.Object |
findRelatedEntity(java.lang.String ejbName,
java.lang.Object primaryKey)
This is public, because it is used by the code generated
abstract entity bean implementations, in the CMR getters. |
void |
init()
Not every service needs to init, implement it out of convenience. |
protected void |
remove(Instance instance)
This method overrides EntityContainer.remove(Instance). |
java.util.Collection |
selectCollection(java.lang.reflect.Method ejbSelectMethod,
java.lang.Object[] args,
EntityInstance entityInstance)
This method is called by ejbSelect() methods in code generated
Entity bean implementations. |
java.lang.Object |
selectObject(java.lang.reflect.Method ejbSelectMethod,
java.lang.Object[] args,
EntityInstance entityInstance)
This method is called by ejbSelect() methods in code generated
Entity bean implementations. |
java.util.Set |
selectSet(java.lang.reflect.Method ejbSelectMethod,
java.lang.Object[] args,
EntityInstance entityInstance)
This method is called by ejbSelect methods() in code generated
Entity bean implementations. |
void |
setCMR(java.lang.String fieldName,
EntityInstance a1EntityInstance,
java.util.Collection cCollection)
For each element in cCollection relate it to the
entity represented by a1EntityInstance. |
void |
setCMR(java.lang.String fieldName,
EntityInstance a1EntityInstance,
java.lang.Object b2Proxy)
Relate the entity represented by b2PrimaryKey to
the entity represented by a1EntityInstance. |
| Methods inherited from class jrun.ejb.EntityContainer |
cacheThreadLocal, createHome, destroy, expungeThreadLocal, findByPrimaryKey, getEJBMetaDataHome, getEntityPersistenceManager, getInstanceCache, getPrimaryKey, getThreadLocalCache, mapHomeMethods, mapObjectMethods, multiFind, remove, removeHome, setEntityPersistenceManager, setInstanceCache, singleFind, start, stop, unsetContext |
| Methods inherited from class jrun.ejb.ClientInvokableContainer |
getEJBHome, getEJBLocalHome, getHomeClass, getHomeHandleHome, getHomeMethodMap, getIdFromHandle, getLocalClass, getLocalHomeClass, getRemoteClass, getRmiBroker, getRoleLink, invokeHomeMethod, isIIOP, isLocal, isLocalInvocation, isRemote, setIIOP, setJNDIName, setRmiBroker |
| Methods inherited from class jrun.ejb.EJBContainer |
createInvokerInterceptor, destroyInterceptors, getBeanClass, getDescription, getDisplayName, getEJBMetaData, getEJBModuleName, getHandle, getInstancePool, getJNDIName, getMethodPermissions, getObjectMethodMap, getPersistenceStore, getSecurityManager, getTransactionManager, initInterceptors, invokeObjectMethod, isIdentical, persistEJBXML, persistJRunEJBXML, setEJBMetaData, setEJBModuleName, setInstancePool, setPersistenceStore, setSecurityManager, setTransactionManager, startInterceptors, stopInterceptors |
| Methods inherited from class jrun.j2ee.J2EEModule |
getClassLoader, getDeploymentOrigin, getEJBPeers, getJ2EEMetaData, isRunning, postStart, resolveEJBLinks, setClassLoader, setDeploymentOrigin, setEJBPeers, setJ2EEMetaData, setName, setRunning |
| Methods inherited from class jrunx.kernel.ServiceAdapter |
bind, findObjectInstance, findObjectInstance, findObjectInstance, getBindToJNDI, getDeactivated, getDomainName, getDomainSearchPath, getJRunService, getLogger, getName, getParentService, getReference, getResourceManager, getServerName, getServerProperties, getStatus, invokeMethod, isInPartition, isPartition, lookup, postDeregister, postRegister, preDeregister, preRegister, requestServer, scheduleRunnable, setBindToJNDI, setDeactivated, setDomainName, setName, setParentService, toString, unbind, unscheduleRunnable, updateStatus |
| Methods inherited from interface jrunx.kernel.ServiceMBean |
bind, getBindToJNDI, getDeactivated, getDomainName, getJRunService, getLogger, getName, getParentService, getServerName, requestServer, setBindToJNDI, setDeactivated, setDomainName, setName, setParentService, unbind |
CMP20EntityContainer
public CMP20EntityContainer()
throws java.lang.Exception
collectionAdd
public void collectionAdd(EJBInvocation ejbInvocation)
collectionAddAll
public void collectionAddAll(EJBInvocation ejbInvocation)
collectionClear
public void collectionClear(EJBInvocation ejbInvocation)
collectionContains
public boolean collectionContains(EJBInvocation ejbInvocation)
collectionContainsAll
public boolean collectionContainsAll(EJBInvocation ejbInvocation)
collectionIsEmpty
public boolean collectionIsEmpty(EJBInvocation ejbInvocation)
collectionIterator
public java.util.Iterator collectionIterator(EJBInvocation ejbInvocation)
collectionRemove
public void collectionRemove(EJBInvocation ejbInvocation)
collectionRemoveAll
public void collectionRemoveAll(EJBInvocation ejbInvocation)
collectionRetainAll
public void collectionRetainAll(EJBInvocation ejbInvocation)
collectionSize
public int collectionSize(EJBInvocation ejbInvocation)
collectionToArray
public java.lang.Object[] collectionToArray(EJBInvocation ejbInvocation)
findRelatedEntities
public java.util.Collection findRelatedEntities(java.lang.String fieldName,
java.lang.String ejbName,
EntityInstance entityInstance)
- This is public, because it is used by the code generated
abstract entity bean implementations, in the CMR getters.
- Parameters:
fieldName - The field name, which is used to construct the
EntityCollection.ejbName - The EJB name of the sink entities.instance - The instance, which is used to
construct the EntityCollection.- Returns:
- An
EntityCollection.
findRelatedEntity
public java.lang.Object findRelatedEntity(java.lang.String ejbName,
java.lang.Object primaryKey)
- This is public, because it is used by the code generated
abstract entity bean implementations, in the CMR getters.
- Parameters:
ejbName - The EJB name of the sink entities.primaryKey - The primary key of the sink entity.- Returns:
- A Proxy for the related entity.
init
public void init()
throws java.lang.Exception
- Description copied from class:
ServiceAdapter
- Not every service needs to init, implement it out of convenience.
- Overrides:
init in class EntityContainer
remove
protected void remove(Instance instance)
throws java.rmi.RemoteException,
javax.ejb.RemoveException
- This method overrides EntityContainer.remove(Instance).
- Overrides:
remove in class EntityContainer
selectCollection
public java.util.Collection selectCollection(java.lang.reflect.Method ejbSelectMethod,
java.lang.Object[] args,
EntityInstance entityInstance)
throws javax.ejb.FinderException
- This method is called by ejbSelect() methods in code generated
Entity bean implementations.
selectObject
public java.lang.Object selectObject(java.lang.reflect.Method ejbSelectMethod,
java.lang.Object[] args,
EntityInstance entityInstance)
throws javax.ejb.FinderException
- This method is called by ejbSelect() methods in code generated
Entity bean implementations. The return type is cast to the
local/remote interface type in the ejbSelect() method
implemenation.
selectSet
public java.util.Set selectSet(java.lang.reflect.Method ejbSelectMethod,
java.lang.Object[] args,
EntityInstance entityInstance)
throws javax.ejb.FinderException
- This method is called by ejbSelect methods() in code generated
Entity bean implementations.
setCMR
public void setCMR(java.lang.String fieldName,
EntityInstance a1EntityInstance,
java.util.Collection cCollection)
- For each element in
cCollection relate it to the
entity represented by a1EntityInstance. Also
unrelate all the entities that were previously related to each
element in cCollection. Lastly unrelate all the
entities previously related to the entity represented by
a1EntityInstance.
- Parameters:
fieldName - The name of the field for this container managed relationship.a1EntityInstance - The instance for the source entity.cCollection - The proxy objects for the sink entities.- Returns:
- A proxy object for the sink entity.
setCMR
public void setCMR(java.lang.String fieldName,
EntityInstance a1EntityInstance,
java.lang.Object b2Proxy)
- Relate the entity represented by
b2PrimaryKey to
the entity represented by a1EntityInstance. Also
unrelate all the entity that was previously related to the
entity represented by b2PrimaryKey. Lastly
unrelate the entity previously related to the entity
represented by a1EntityInstance.
- Parameters:
fieldName - The name of the field for this container managed relationship.a1EntityInstance - The instance for the source entity.b2Proxy - The proxy for the sink entity.- Returns:
- A proxy object for the sink entity.
Copyright � 2002 Macromedia Corporation. All Rights Reserved.