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

All Superinterfaces:
org.eclipse.core.runtime.IAdaptable, IResourcePart, JpaContextNode, JpaNode, JpaStructureNode, Model, PersistentAttribute, XmlContextNode

public interface OrmPersistentAttribute
extends PersistentAttribute, XmlContextNode

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
 
Fields inherited from interface org.eclipse.jpt.core.context.PersistentAttribute
DEFAULT_MAPPING_PROPERTY, NAME_PROPERTY, SPECIFIED_MAPPING_PROPERTY
 
Method Summary
 boolean contains(int textOffset)
           
 OrmAttributeMapping getMapping()
          Overriden to return OrmAttributeMappings
 OrmPersistentType getPersistentType()
          Overriden to return OrmPersistentTypes
 OrmAttributeMapping getSpecifiedMapping()
          Overriden to return OrmAttributeMappings
 OrmTypeMapping getTypeMapping()
          Overriden to return OrmTypeMappings
 void initialize(XmlAttributeMapping attributeMapping)
           
 void makeSpecified()
          Take a virtual persistent attribute and specify it.
 void makeSpecified(java.lang.String mappingKey)
          Take a virtual persistent attribute and specify it.
 void makeVirtual()
          Make the persistent attribute virtual.
 void nameChanged(java.lang.String oldName, java.lang.String newName)
           
 void update()
          Update the OrmPersistentAttribute context model object to match the resource model object.
 
Methods inherited from interface org.eclipse.jpt.core.context.PersistentAttribute
getDefaultMappingKey, getMappingKey, getName, getPrimaryKeyColumnName, isIdAttribute, isOverridableAssociation, isOverridableAttribute, isVirtual, setSpecifiedMappingKey
 
Methods inherited from interface org.eclipse.jpt.core.context.JpaContextNode
getContextDefaultDbCatalog, getContextDefaultDbSchema, getContextDefaultDbSchemaContainer, getMappingFileRoot, getPersistenceUnit
 
Methods inherited from interface org.eclipse.jpt.core.JpaNode
getJpaProject, getParent
 
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.IResourcePart
getResource
 
Methods inherited from interface org.eclipse.jpt.core.JpaStructureNode
dispose, getId, getSelectionTextRange, getStructureNode
 
Methods inherited from interface org.eclipse.jpt.core.JpaNode
getJpaProject, getParent
 
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.IResourcePart
getResource
 
Methods inherited from interface org.eclipse.jpt.core.context.XmlContextNode
getEResource, getValidationTextRange, validate
 
Methods inherited from interface org.eclipse.jpt.core.context.JpaContextNode
getContextDefaultDbCatalog, getContextDefaultDbSchema, getContextDefaultDbSchemaContainer, getMappingFileRoot, getPersistenceUnit
 
Methods inherited from interface org.eclipse.jpt.core.JpaNode
getJpaProject, getParent
 
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.IResourcePart
getResource
 

Method Detail

getMapping

OrmAttributeMapping getMapping()
Overriden to return OrmAttributeMappings

Specified by:
getMapping in interface PersistentAttribute

getSpecifiedMapping

OrmAttributeMapping getSpecifiedMapping()
Overriden to return OrmAttributeMappings

Specified by:
getSpecifiedMapping in interface PersistentAttribute

getTypeMapping

OrmTypeMapping getTypeMapping()
Overriden to return OrmTypeMappings

Specified by:
getTypeMapping in interface PersistentAttribute

getPersistentType

OrmPersistentType getPersistentType()
Overriden to return OrmPersistentTypes

Specified by:
getPersistentType in interface PersistentAttribute

contains

boolean contains(int textOffset)

makeVirtual

void makeVirtual()
Make the persistent attribute virtual. The attribute will be removed from the list of specified persistent attributes on the OrmPersistentType and removed from the orm.xml file. If the persistent attribute is already virtual, an IllegalStateException is thrown

See Also:
PersistentAttribute.isVirtual()

makeSpecified

void makeSpecified()
Take a virtual persistent attribute and specify it. The attribute will be added to the list of specified persistent attributes and added to the orm.xml file. The mappingKey will remain the same. If the persistent attribute is already specified, an IllegalStateException is thrown

See Also:
PersistentAttribute.isVirtual()

makeSpecified

void makeSpecified(java.lang.String mappingKey)
Take a virtual persistent attribute and specify it. The attribute will be added to the list of specified persistent attributes and added to the orm.xml file. The mappingKey will determine the type of mapping added instead of the mappingKey already on the persistent attribute If the persistent attribute is already specified, an IllegalStateException is thrown

See Also:
PersistentAttribute.isVirtual()

nameChanged

void nameChanged(java.lang.String oldName,
                 java.lang.String newName)

initialize

void initialize(XmlAttributeMapping attributeMapping)

update

void update()
Update the OrmPersistentAttribute context model object to match the resource model object. see JpaProject.update()