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

All Superinterfaces:
AttributeMapping, org.eclipse.core.runtime.IAdaptable, IResourcePart, JpaContextNode, JpaNode, Model, XmlContextNode
All Known Subinterfaces:
OrmBaseEmbeddedMapping, OrmBasicMapping, OrmEmbeddedIdMapping, OrmEmbeddedMapping, OrmIdMapping, OrmManyToManyMapping, OrmManyToOneMapping, OrmMultiRelationshipMapping, OrmOneToManyMapping, OrmOneToOneMapping, OrmRelationshipMapping, OrmSingleRelationshipMapping, OrmTransientMapping, OrmVersionMapping

public interface OrmAttributeMapping
extends AttributeMapping, 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
static java.lang.String NAME_PROPERTY
           
 
Method Summary
 void addToResourceModel(Attributes resourceAttributes)
           
 boolean contains(int textOffset)
           
 java.lang.String getName()
           
 TextRange getNameTextRange()
           
 OrmPersistentAttribute getPersistentAttribute()
           
 XmlAttributeMapping getResourceAttributeMapping()
           
 TextRange getSelectionTextRange()
           
 int getXmlSequence()
          Attributes are a sequence in the orm schema.
 void initializeFromOrmAttributeMapping(OrmAttributeMapping oldMapping)
           
 void initializeFromOrmBasicMapping(OrmBasicMapping oldMapping)
           
 void initializeFromOrmEmbeddedIdMapping(OrmEmbeddedIdMapping oldMapping)
           
 void initializeFromOrmEmbeddedMapping(OrmEmbeddedMapping oldMapping)
           
 void initializeFromOrmIdMapping(OrmIdMapping oldMapping)
           
 void initializeFromOrmManyToManyMapping(OrmManyToManyMapping oldMapping)
           
 void initializeFromOrmManyToOneMapping(OrmManyToOneMapping oldMapping)
           
 void initializeFromOrmOneToManyMapping(OrmOneToManyMapping oldMapping)
           
 void initializeFromOrmOneToOneMapping(OrmOneToOneMapping oldMapping)
           
 void initializeFromOrmTransientMapping(OrmTransientMapping oldMapping)
           
 void initializeFromOrmVersionMapping(OrmVersionMapping oldMapping)
           
 void initializeOn(OrmAttributeMapping newMapping)
           
 void removeFromResourceModel(Attributes resourceAttributes)
           
 void setName(java.lang.String newName)
           
 void update()
          Update the OrmAttributeMapping context model object to match the resource model object.
 
Methods inherited from interface org.eclipse.jpt.core.context.AttributeMapping
getKey, getPrimaryKeyColumnName, getTypeMapping, isDefault, isIdMapping, isOverridableAssociationMapping, isOverridableAttributeMapping, isOwnedBy, shouldValidateAgainstDatabase
 
Methods inherited from interface org.eclipse.jpt.core.context.JpaContextNode
getContextDefaultDbCatalog, getContextDefaultDbSchema, getContextDefaultDbSchemaContainer, getMappingFileRoot, getPersistenceUnit, postUpdate
 
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
getValidationTextRange, validate
 
Methods inherited from interface org.eclipse.jpt.core.context.JpaContextNode
getContextDefaultDbCatalog, getContextDefaultDbSchema, getContextDefaultDbSchemaContainer, getMappingFileRoot, getPersistenceUnit, postUpdate
 
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
 

Field Detail

NAME_PROPERTY

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

getPersistentAttribute

OrmPersistentAttribute getPersistentAttribute()
Specified by:
getPersistentAttribute in interface AttributeMapping

getResourceAttributeMapping

XmlAttributeMapping getResourceAttributeMapping()

getName

java.lang.String getName()
Specified by:
getName in interface AttributeMapping

setName

void setName(java.lang.String newName)

getXmlSequence

int getXmlSequence()
Attributes are a sequence in the orm schema. We must keep the list of attributes in the appropriate order so the wtp xml translators will write them to the xml in that order and they will adhere to the schema. Each concrete subclass of XmlAttributeMapping must implement this method and return an int that matches it's order in the schema

Returns:

addToResourceModel

void addToResourceModel(Attributes resourceAttributes)

removeFromResourceModel

void removeFromResourceModel(Attributes resourceAttributes)

initializeOn

void initializeOn(OrmAttributeMapping newMapping)

initializeFromOrmAttributeMapping

void initializeFromOrmAttributeMapping(OrmAttributeMapping oldMapping)

initializeFromOrmBasicMapping

void initializeFromOrmBasicMapping(OrmBasicMapping oldMapping)

initializeFromOrmIdMapping

void initializeFromOrmIdMapping(OrmIdMapping oldMapping)

initializeFromOrmTransientMapping

void initializeFromOrmTransientMapping(OrmTransientMapping oldMapping)

initializeFromOrmEmbeddedMapping

void initializeFromOrmEmbeddedMapping(OrmEmbeddedMapping oldMapping)

initializeFromOrmEmbeddedIdMapping

void initializeFromOrmEmbeddedIdMapping(OrmEmbeddedIdMapping oldMapping)

initializeFromOrmVersionMapping

void initializeFromOrmVersionMapping(OrmVersionMapping oldMapping)

initializeFromOrmOneToManyMapping

void initializeFromOrmOneToManyMapping(OrmOneToManyMapping oldMapping)

initializeFromOrmManyToOneMapping

void initializeFromOrmManyToOneMapping(OrmManyToOneMapping oldMapping)

initializeFromOrmOneToOneMapping

void initializeFromOrmOneToOneMapping(OrmOneToOneMapping oldMapping)

initializeFromOrmManyToManyMapping

void initializeFromOrmManyToManyMapping(OrmManyToManyMapping oldMapping)

contains

boolean contains(int textOffset)

getSelectionTextRange

TextRange getSelectionTextRange()

getNameTextRange

TextRange getNameTextRange()

update

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