org.eclipse.jpt.core.context.orm
Interface OrmPersistentType

All Superinterfaces:
org.eclipse.core.runtime.IAdaptable, JpaContextNode, JpaNode, JpaStructureNode, Model, OrmJpaContextNode, PersistentType

public interface OrmPersistentType
extends PersistentType, OrmJpaContextNode

Provisional API: This interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.


Field Summary
static java.lang.String VIRTUAL_ATTRIBUTES_LIST
           
 
Fields inherited from interface org.eclipse.jpt.core.context.PersistentType
ACCESS_PROPERTY, MAPPING_PROPERTY, NAME_PROPERTY, PARENT_PERSISTENT_TYPE_PROPERTY, SPECIFIED_ATTRIBUTES_LIST
 
Method Summary
 OrmPersistentAttribute addSpecifiedPersistentAttribute(java.lang.String mappingKey, java.lang.String attributeName)
           
 java.util.ListIterator<OrmPersistentAttribute> attributes()
          Overriden to return OrmPersistentAttributes
 void changeMapping(OrmPersistentAttribute ormPersistentAttribute, OrmAttributeMapping oldMapping, OrmAttributeMapping newMapping)
           
 void classChanged(java.lang.String oldClass, java.lang.String newClass)
           
 boolean contains(int textOffset)
           
 boolean containsVirtualPersistentAttribute(OrmPersistentAttribute ormPersistentAttribute)
          Return whether this persistent type contains the given virtual persistent attribute.
 OrmPersistentAttribute getAttributeNamed(java.lang.String attributeName)
          Overriden to return an OrmPersistentAttribute
 JavaPersistentType getJavaPersistentType()
          Return the Java persistent type that is referred to by this orm.xml persistent type.
 OrmTypeMapping getMapping()
          Overriden to return an OrmTypeMapping
 void initialize(XmlEmbeddable embeddable)
           
 void initialize(XmlEntity entity)
           
 void initialize(XmlMappedSuperclass mappedSuperclass)
           
 boolean isFor(java.lang.String fullyQualifiedTypeName)
          Return whether this {@link OrmPersistentType) applies to the given fullyQualifiedTypeName.
 void makePersistentAttributeSpecified(OrmPersistentAttribute ormPersistentAttribute)
          Add the given virtual orm persistent attribute to the orm.xml.
 void makePersistentAttributeSpecified(OrmPersistentAttribute ormPersistentAttribute, java.lang.String mappingKey)
          Add the given virtual orm persistent attribute to the orm.xml with a mapping of type mappingKey.
 void makePersistentAttributeVirtual(OrmPersistentAttribute ormPersistentAttribute)
          Remove the given specified orm persistent attribute from the orm.xml.
 void removeSpecifiedPersistentAttribute(OrmPersistentAttribute ormPersistentAttribute)
           
 java.util.ListIterator<OrmPersistentAttribute> specifiedAttributes()
          Return a read only iterator of the specified OrmPersistentAttributes.
 int specifiedAttributesSize()
          Return the number of specified OrmPersistentAttributes.
 void update(XmlEmbeddable embeddable)
           
 void update(XmlEntity entity)
           
 void update(XmlMappedSuperclass mappedSuperclass)
           
 java.util.ListIterator<OrmPersistentAttribute> virtualAttributes()
          Return a read only iterator of the virtual orm persistent attributes.
 int virtualAttributesSize()
          Return the number of virtual orm persistent attributes.
 
Methods inherited from interface org.eclipse.jpt.core.context.PersistentType
addToMessages, allAttributeNames, allAttributes, attributeNames, attributesSize, getAccess, getMappingKey, getName, getParentPersistentType, inheritanceHierarchy, isMapped, resolveAttribute, setMappingKey
 
Methods inherited from interface org.eclipse.jpt.core.context.JpaContextNode
getEntityMappings, getOrmPersistentType, getPersistenceUnit
 
Methods inherited from interface org.eclipse.jpt.core.JpaNode
getJpaProject, getParent, getResource
 
Methods inherited from interface org.eclipse.jpt.utility.model.Model
addCollectionChangeListener, addCollectionChangeListener, addListChangeListener, addListChangeListener, addPropertyChangeListener, addPropertyChangeListener, addStateChangeListener, addTreeChangeListener, addTreeChangeListener, removeCollectionChangeListener, removeCollectionChangeListener, removeListChangeListener, removeListChangeListener, removePropertyChangeListener, removePropertyChangeListener, removeStateChangeListener, removeTreeChangeListener, removeTreeChangeListener
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 
Methods inherited from interface org.eclipse.jpt.core.JpaStructureNode
dispose, getId, getSelectionTextRange, getStructureNode
 
Methods inherited from interface org.eclipse.jpt.core.JpaNode
getJpaProject, getParent, getResource
 
Methods inherited from interface org.eclipse.jpt.utility.model.Model
addCollectionChangeListener, addCollectionChangeListener, addListChangeListener, addListChangeListener, addPropertyChangeListener, addPropertyChangeListener, addStateChangeListener, addTreeChangeListener, addTreeChangeListener, removeCollectionChangeListener, removeCollectionChangeListener, removeListChangeListener, removeListChangeListener, removePropertyChangeListener, removePropertyChangeListener, removeStateChangeListener, removeTreeChangeListener, removeTreeChangeListener
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 
Methods inherited from interface org.eclipse.jpt.core.context.orm.OrmJpaContextNode
addToMessages, getValidationTextRange
 
Methods inherited from interface org.eclipse.jpt.core.context.JpaContextNode
getEntityMappings, getOrmPersistentType, getPersistenceUnit
 
Methods inherited from interface org.eclipse.jpt.core.JpaNode
getJpaProject, getParent, getResource
 
Methods inherited from interface org.eclipse.jpt.utility.model.Model
addCollectionChangeListener, addCollectionChangeListener, addListChangeListener, addListChangeListener, addPropertyChangeListener, addPropertyChangeListener, addStateChangeListener, addTreeChangeListener, addTreeChangeListener, removeCollectionChangeListener, removeCollectionChangeListener, removeListChangeListener, removeListChangeListener, removePropertyChangeListener, removePropertyChangeListener, removeStateChangeListener, removeTreeChangeListener, removeTreeChangeListener
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 

Field Detail

VIRTUAL_ATTRIBUTES_LIST

static final java.lang.String VIRTUAL_ATTRIBUTES_LIST
See Also:
Constant Field Values
Method Detail

attributes

java.util.ListIterator<OrmPersistentAttribute> attributes()
Overriden to return OrmPersistentAttributes

Specified by:
attributes in interface PersistentType

getAttributeNamed

OrmPersistentAttribute getAttributeNamed(java.lang.String attributeName)
Overriden to return an OrmPersistentAttribute

Specified by:
getAttributeNamed in interface PersistentType

getMapping

OrmTypeMapping getMapping()
Overriden to return an OrmTypeMapping

Specified by:
getMapping in interface PersistentType

specifiedAttributes

java.util.ListIterator<OrmPersistentAttribute> specifiedAttributes()
Return a read only iterator of the specified OrmPersistentAttributes.


specifiedAttributesSize

int specifiedAttributesSize()
Return the number of specified OrmPersistentAttributes.


addSpecifiedPersistentAttribute

OrmPersistentAttribute addSpecifiedPersistentAttribute(java.lang.String mappingKey,
                                                       java.lang.String attributeName)

removeSpecifiedPersistentAttribute

void removeSpecifiedPersistentAttribute(OrmPersistentAttribute ormPersistentAttribute)

virtualAttributes

java.util.ListIterator<OrmPersistentAttribute> virtualAttributes()
Return a read only iterator of the virtual orm persistent attributes. These are attributes that exist in the underyling java class, but are not specified in the orm.xml


virtualAttributesSize

int virtualAttributesSize()
Return the number of virtual orm persistent attributes. These are attributes that exist in the underyling java class, but are not specified in the orm.xml


containsVirtualPersistentAttribute

boolean containsVirtualPersistentAttribute(OrmPersistentAttribute ormPersistentAttribute)
Return whether this persistent type contains the given virtual persistent attribute.


makePersistentAttributeVirtual

void makePersistentAttributeVirtual(OrmPersistentAttribute ormPersistentAttribute)
Remove the given specified orm persistent attribute from the orm.xml. The attribute will be removed from the orm.xml and moved from the list of specified attributes to the list of virtual attributes.


makePersistentAttributeSpecified

void makePersistentAttributeSpecified(OrmPersistentAttribute ormPersistentAttribute)
Add the given virtual orm persistent attribute to the orm.xml. The attribute will be added to the orm.xml and moved from the list of virtual attributes to the list of specified attributes


makePersistentAttributeSpecified

void makePersistentAttributeSpecified(OrmPersistentAttribute ormPersistentAttribute,
                                      java.lang.String mappingKey)
Add the given virtual orm persistent attribute to the orm.xml with a mapping of type mappingKey. The attribute will be added to the orm.xml and moved from the list of virtual attributes to the list of specified attributes


changeMapping

void changeMapping(OrmPersistentAttribute ormPersistentAttribute,
                   OrmAttributeMapping oldMapping,
                   OrmAttributeMapping newMapping)

initialize

void initialize(XmlEntity entity)

initialize

void initialize(XmlMappedSuperclass mappedSuperclass)

initialize

void initialize(XmlEmbeddable embeddable)

update

void update(XmlEntity entity)

update

void update(XmlMappedSuperclass mappedSuperclass)

update

void update(XmlEmbeddable embeddable)

contains

boolean contains(int textOffset)

isFor

boolean isFor(java.lang.String fullyQualifiedTypeName)
Return whether this {@link OrmPersistentType) applies to the given fullyQualifiedTypeName.


classChanged

void classChanged(java.lang.String oldClass,
                  java.lang.String newClass)

getJavaPersistentType

JavaPersistentType getJavaPersistentType()
Return the Java persistent type that is referred to by this orm.xml persistent type. If there is no underlying java persistent type, then null is returned.

Returns: