Class EISCompositeObjectMapping

java.lang.Object
org.eclipse.persistence.core.mappings.CoreMapping<AttributeAccessor,org.eclipse.persistence.internal.sessions.AbstractSession,org.eclipse.persistence.internal.queries.ContainerPolicy,ClassDescriptor,org.eclipse.persistence.internal.helper.DatabaseField>
All Implemented Interfaces:
Serializable, Cloneable, EISMapping

public class EISCompositeObjectMapping extends AbstractCompositeObjectMapping implements EISMapping

EIS Composite Object Mappings map a Java object to a privately owned, one-to-one relationship to an EIS Record according to its descriptor's record type.

Record formats
Record Type Description
Indexed Ordered collection of record elements. The indexed record EIS format enables Java class attribute values to be retreived by position or index.
Mapped Key-value map based representation of record elements. The mapped record EIS format enables Java class attribute values to be retreived by an object key.
XML Record/Map representation of an XML DOM element.
See Also:
  • Constructor Details

    • EISCompositeObjectMapping

      public EISCompositeObjectMapping()
  • Method Details

    • isEISMapping

      public boolean isEISMapping()
      INTERNAL:
      Overrides:
      isEISMapping in class DatabaseMapping
    • getXPath

      public String getXPath()
      Get the XPath String
      Returns:
      String the XPath String associated with this Mapping
    • setXPath

      public void setXPath(String xpathString)
      Set the Mapping field name attribute to the given XPath String
      Parameters:
      xpathString - String
    • getFieldName

      public String getFieldName()
      PUBLIC: Return the name of the field mapped by the mapping.
    • setFieldName

      public void setFieldName(String fieldName)
      PUBLIC: Set the name of the field mapped by the mapping.
    • buildCompositeRow

      protected Object buildCompositeRow(Object attributeValue, org.eclipse.persistence.internal.sessions.AbstractSession session, org.eclipse.persistence.internal.sessions.AbstractRecord record, DatabaseMapping.WriteType writeType)
      Specified by:
      buildCompositeRow in class AbstractCompositeObjectMapping
    • buildCompositeObject

      protected Object buildCompositeObject(org.eclipse.persistence.internal.descriptors.ObjectBuilder objectBuilder, org.eclipse.persistence.internal.sessions.AbstractRecord nestedRow, ObjectBuildingQuery query, org.eclipse.persistence.internal.identitymaps.CacheKey parentCacheKey, org.eclipse.persistence.internal.queries.JoinedAttributeManager joinManager, org.eclipse.persistence.internal.sessions.AbstractSession targetSession)
      Specified by:
      buildCompositeObject in class AbstractCompositeObjectMapping
    • writeFromObjectIntoRow

      public void writeFromObjectIntoRow(Object object, org.eclipse.persistence.internal.sessions.AbstractRecord record, org.eclipse.persistence.internal.sessions.AbstractSession session, DatabaseMapping.WriteType writeType) throws DescriptorException
      INTERNAL: Build the value for the database field and put it in the specified database row.
      Overrides:
      writeFromObjectIntoRow in class AbstractCompositeObjectMapping
      Throws:
      DescriptorException
    • preInitialize

      public void preInitialize(org.eclipse.persistence.internal.sessions.AbstractSession session)
      Fix field names for XML data descriptors. Since fields are fixed to use text() by default in descriptor, ensure the correct non text field is used here.
      Overrides:
      preInitialize in class DatabaseMapping
    • postInitialize

      public void postInitialize(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorException
      INTERNAL: Initialize the mapping.
      Overrides:
      postInitialize in class DatabaseMapping
      Throws:
      DescriptorException