FileDocCategorySizeDatePackage
JDOEJB20Helper.javaAPI DocGlassfish v2 API5812Fri May 04 22:35:04 BST 2007com.sun.jdo.spi.persistence.support.sqlstore.ejb

JDOEJB20Helper

public interface JDOEJB20Helper implements JDOEJB11Helper

Fields Summary
Constructors Summary
Methods Summary
public voidassertInstanceOfLocalInterfaceImpl(java.lang.Object o)
Validates that this instance is of the correct implementation class of a local interface type.

param
o the instance to validate.
return
true if the type is correct.
throw
IllegalArgumentException if validation fails.

public java.util.CollectionconvertCollectionEJBLocalObjectToPC(java.util.Collection coll, com.sun.jdo.api.persistence.support.PersistenceManager pm, boolean validate)
Converts Collection of EJBLocalObjects to a Collection of persistence-capable instances.

param
coll the Collection of EJBLocalObject instances to be converted.
param
pm the associated instance of PersistenceManager.
param
validate true if the existence of the instances is to be validated.
return
Collection of persistence-capable instance.
throw
IllegalArgumentException if validate is true and at least one instance does not exist in the database or is deleted.

public java.util.CollectionconvertCollectionPCToEJBLocalObject(java.util.Collection pcs, com.sun.jdo.api.persistence.support.PersistenceManager pm)
Converts Collection of persistence-capable instances to a Collection of EJBLocalObjects.

param
pcs the Collection of persistence-capable instance to be converted.
param
pm the associated instance of PersistenceManager.
return
Collection of EJBLocalObjects.

public java.util.SetconvertCollectionPCToEJBLocalObjectSet(java.util.Collection pcs, com.sun.jdo.api.persistence.support.PersistenceManager pm)
Converts Collection of persistence-capable instances to a Set of EJBLocalObjects.

param
pcs the Collection of persistence-capable instance to be converted.
param
pm the associated instance of PersistenceManager.
return
Set of EJBLocalObjects.

public java.lang.ObjectconvertEJBLocalObjectToPC(javax.ejb.EJBLocalObject o, com.sun.jdo.api.persistence.support.PersistenceManager pm, boolean validate)
Converts EJBLocalObject to persistence-capable instance.

param
o the EJBLocalObject instance to be converted.
param
pm the associated instance of PersistenceManager.
param
validate true if the existence of the instance is to be validated.
return
persistence-capable instance.
throw
IllegalArgumentException if validate is true and instance does not exist in the database or is deleted.

public javax.ejb.EJBLocalObjectconvertPCToEJBLocalObject(java.lang.Object pc, com.sun.jdo.api.persistence.support.PersistenceManager pm)
Converts persistence-capable instance to EJBLocalObject.

param
pc the persistence-capable instance to be converted as an Object.
param
pm the associated instance of PersistenceManager.
return
instance of EJBLocalObject.

public javax.ejb.EJBLocalObjectconvertPCToEJBLocalObject(java.lang.Object pc, com.sun.jdo.api.persistence.support.PersistenceManager pm, javax.ejb.EJBContext context)
Converts persistence-capable instance to EJBLocalObject. Returns null if the instance is already removed via cascade-delete operation.

param
pc the persistence-capable instance to be converted as an Object.
param
pm the associated instance of PersistenceManager.
param
context the EJBContext of the calling bean.
return
instance of EJBLocalObject.