EclipseLink 2.5.0, build 'v20130507-3faac2b' API Reference

org.eclipse.persistence.core.descriptors
Class CoreInheritancePolicy<ABSTRACT_RECORD extends org.eclipse.persistence.internal.core.sessions.CoreAbstractRecord,ABSTRACT_SESSION extends org.eclipse.persistence.internal.core.sessions.CoreAbstractSession,DESCRIPTOR extends CoreDescriptor,FIELD extends org.eclipse.persistence.internal.core.helper.CoreField>

java.lang.Object
  extended by org.eclipse.persistence.core.descriptors.CoreInheritancePolicy<ABSTRACT_RECORD,ABSTRACT_SESSION,DESCRIPTOR,FIELD>
Direct Known Subclasses:
InheritancePolicy

public abstract class CoreInheritancePolicy<ABSTRACT_RECORD extends org.eclipse.persistence.internal.core.sessions.CoreAbstractRecord,ABSTRACT_SESSION extends org.eclipse.persistence.internal.core.sessions.CoreAbstractSession,DESCRIPTOR extends CoreDescriptor,FIELD extends org.eclipse.persistence.internal.core.helper.CoreField>
extends java.lang.Object

INTERNAL A abstraction of inheritance policy capturing behavior common to all persistence types.


Constructor Summary
CoreInheritancePolicy()
           
 
Method Summary
abstract  void addClassIndicatorFieldToRow(ABSTRACT_RECORD databaseRow)
          INTERNAL: Add abstract class indicator information to the database row.
abstract  void addClassNameIndicator(java.lang.String childClassName, java.lang.Object typeValue)
          INTERNAL: Add the class name reference by class name, used by the MW.
abstract  java.lang.Class classFromRow(ABSTRACT_RECORD record, ABSTRACT_SESSION session)
          INTERNAL: This method is invoked only for the abstract descriptors.
abstract  java.util.List<DESCRIPTOR> getAllChildDescriptors()
          INTERNAL: Returns all the child descriptors, even descriptors for subclasses of subclasses.
abstract  FIELD getClassIndicatorField()
          INTERNAL: Returns field that the class type indicator is store when using inheritance.
abstract  java.lang.String getClassIndicatorFieldName()
          PUBLIC: Return the class indicator field name.
abstract  java.util.Map getClassIndicatorMapping()
          INTERNAL: Return the association of indicators and classes using specified ConversionManager
abstract  java.util.Map getClassNameIndicatorMapping()
          INTERNAL: Return the mapping from class name to indicator, used by MW.
abstract  DESCRIPTOR getDescriptor()
          INTERNAL: Returns the descriptor which the policy belongs to.
abstract  java.lang.Class getParentClass()
          PUBLIC: Return the parent class.
abstract  DESCRIPTOR getParentDescriptor()
          INTERNAL: Return the parent descriptor.
abstract  boolean hasClassExtractor()
          INTERNAL:
abstract  boolean isRootParentDescriptor()
          INTERNAL: Return whether or not is root parent descriptor
abstract  void setClassExtractorName(java.lang.String classExtractorName)
          ADVANCED: Set the class extractor class name.
abstract  void setClassIndicatorField(FIELD classIndicatorField)
          ADVANCED: To set the class indicator field.
abstract  void setClassIndicatorMapping(java.util.Map classIndicatorMapping)
          PUBLIC: Set the association of indicators and classes.
abstract  void setDescriptor(DESCRIPTOR descriptor)
          INTERNAL: Set the descriptor.
abstract  void setParentClassName(java.lang.String parentClassName)
          INTERNAL: Set the parent class name, used by MW to avoid referencing the real class for deployment XML generation.
abstract  void setShouldReadSubclasses(java.lang.Boolean shouldReadSubclasses)
          INTERNAL: Set the descriptor to read instance of itself and its subclasses when queried.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CoreInheritancePolicy

public CoreInheritancePolicy()
Method Detail

addClassIndicatorFieldToRow

public abstract void addClassIndicatorFieldToRow(ABSTRACT_RECORD databaseRow)
INTERNAL: Add abstract class indicator information to the database row. This is required when building a row for an insert or an update of a concrete child descriptor.


addClassNameIndicator

public abstract void addClassNameIndicator(java.lang.String childClassName,
                                           java.lang.Object typeValue)
INTERNAL: Add the class name reference by class name, used by the MW.


classFromRow

public abstract java.lang.Class classFromRow(ABSTRACT_RECORD record,
                                             ABSTRACT_SESSION session)
INTERNAL: This method is invoked only for the abstract descriptors.


getAllChildDescriptors

public abstract java.util.List<DESCRIPTOR> getAllChildDescriptors()
INTERNAL: Returns all the child descriptors, even descriptors for subclasses of subclasses. Required for bug 3019934.


getClassIndicatorField

public abstract FIELD getClassIndicatorField()
INTERNAL: Returns field that the class type indicator is store when using inheritance.


getClassIndicatorFieldName

public abstract java.lang.String getClassIndicatorFieldName()
PUBLIC: Return the class indicator field name. This is the name of the field in the table that stores what type of object this is.


getClassIndicatorMapping

public abstract java.util.Map getClassIndicatorMapping()
INTERNAL: Return the association of indicators and classes using specified ConversionManager


getClassNameIndicatorMapping

public abstract java.util.Map getClassNameIndicatorMapping()
INTERNAL: Return the mapping from class name to indicator, used by MW.


getDescriptor

public abstract DESCRIPTOR getDescriptor()
INTERNAL: Returns the descriptor which the policy belongs to.


getParentClass

public abstract java.lang.Class getParentClass()
PUBLIC: Return the parent class.


getParentDescriptor

public abstract DESCRIPTOR getParentDescriptor()
INTERNAL: Return the parent descriptor.


hasClassExtractor

public abstract boolean hasClassExtractor()
INTERNAL:


isRootParentDescriptor

public abstract boolean isRootParentDescriptor()
INTERNAL: Return whether or not is root parent descriptor


setClassExtractorName

public abstract void setClassExtractorName(java.lang.String classExtractorName)
ADVANCED: Set the class extractor class name. At descriptor initialize time this class will be converted to a Class and set as the ClassExtractor. This method is called from JPA.

See Also:
for more information on the ClassExtractor class.

setClassIndicatorField

public abstract void setClassIndicatorField(FIELD classIndicatorField)
ADVANCED: To set the class indicator field. This can be used for advanced field types, such as XML nodes, or to set the field type.


setClassIndicatorMapping

public abstract void setClassIndicatorMapping(java.util.Map classIndicatorMapping)
PUBLIC: Set the association of indicators and classes. This may be desired to be used by clients in strange inheritance models.


setDescriptor

public abstract void setDescriptor(DESCRIPTOR descriptor)
INTERNAL: Set the descriptor.


setParentClassName

public abstract void setParentClassName(java.lang.String parentClassName)
INTERNAL: Set the parent class name, used by MW to avoid referencing the real class for deployment XML generation.


setShouldReadSubclasses

public abstract void setShouldReadSubclasses(java.lang.Boolean shouldReadSubclasses)
INTERNAL: Set the descriptor to read instance of itself and its subclasses when queried. This is used with inheritance to configure the result of queries. By default this is true for root inheritance descriptors, and false for all others.


EclipseLink 2.5.0, build 'v20130507-3faac2b' API Reference