|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Entity
entity
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 |
DEFAULT_DISCRIMINATOR_VALUE_PROPERTY
|
static java.lang.String |
DEFAULT_INHERITANCE_STRATEGY_PROPERTY
|
static java.lang.String |
DEFAULT_NAME_PROPERTY
|
static java.lang.String |
DESCENDANTS_COLLECTION
|
static java.lang.String |
DISCRIMINATOR_COLUMN_IS_UNDEFINED_PROPERTY
|
static java.lang.String |
DISCRIMINATOR_VALUE_IS_UNDEFINED_PROPERTY
|
static java.lang.String |
ROOT_ENTITY_PROPERTY
|
static java.lang.String |
SPECIFIED_DISCRIMINATOR_COLUMN_IS_ALLOWED_PROPERTY
|
static java.lang.String |
SPECIFIED_DISCRIMINATOR_VALUE_IS_ALLOWED_PROPERTY
|
static java.lang.String |
SPECIFIED_DISCRIMINATOR_VALUE_PROPERTY
|
static java.lang.String |
SPECIFIED_INHERITANCE_STRATEGY_PROPERTY
|
static java.lang.String |
SPECIFIED_NAME_PROPERTY
|
static java.lang.String |
SPECIFIED_PRIMARY_KEY_JOIN_COLUMNS_LIST
|
static java.lang.String |
SPECIFIED_SECONDARY_TABLES_LIST
|
static java.lang.String |
SPECIFIED_TABLE_IS_ALLOWED_PROPERTY
|
static java.lang.String |
TABLE_IS_UNDEFINED_PROPERTY
|
| Method Summary | |
|---|---|
PrimaryKeyJoinColumn |
addSpecifiedPrimaryKeyJoinColumn()
|
PrimaryKeyJoinColumn |
addSpecifiedPrimaryKeyJoinColumn(int index)
|
SecondaryTable |
addSpecifiedSecondaryTable()
Add a specified secondary table to the entity return the object representing it. |
SecondaryTable |
addSpecifiedSecondaryTable(int index)
Add a specified secondary table to the entity return the object representing it. |
boolean |
discriminatorColumnIsUndefined()
Return whether a DiscriminatorColumn is undefined for this Entity. |
boolean |
discriminatorValueIsUndefined()
Return whether a DiscriminatorValue is undefined for this Entity. |
AssociationOverrideContainer |
getAssociationOverrideContainer()
|
AttributeOverrideContainer |
getAttributeOverrideContainer()
|
java.lang.String |
getDefaultCatalog()
Return the entity's default catalog, which depends on the entity's inheritance hierarchy. |
java.lang.String |
getDefaultDiscriminatorValue()
|
InheritanceType |
getDefaultInheritanceStrategy()
|
java.lang.String |
getDefaultName()
|
java.lang.String |
getDefaultSchema()
Return the entity's default schema, which depends on the entity's inheritance hierarchy. |
java.lang.String |
getDefaultTableName()
Return the entity's default table name, which depends on the entity's inheritance hierarchy. |
java.lang.Iterable<Entity> |
getDescendants()
If the entity is a root entity, return the entity's descendant entities; if the entity is not a root entity, return an empty collection. |
DiscriminatorColumn |
getDiscriminatorColumn()
|
java.lang.String |
getDiscriminatorValue()
|
GeneratorContainer |
getGeneratorContainer()
|
PersistentAttribute |
getIdAttribute()
If an entity has a single id attribute, return that attribute. |
IdClassReference |
getIdClassReference()
Return the (aggregate) class reference for configuring and validating id class |
InheritanceType |
getInheritanceStrategy()
Return the specified inheritance strategy if present, otherwise return the default inheritance strategy. |
Entity |
getParentEntity()
The first parent in the class hierarchy that is an entity. |
java.lang.String |
getPrimaryKeyColumnName()
Return the name of the entity's primary key column. |
QueryContainer |
getQueryContainer()
|
Entity |
getRootEntity()
Return the top of the entity's inheritance hierarchy. |
java.lang.String |
getSpecifiedDiscriminatorValue()
|
InheritanceType |
getSpecifiedInheritanceStrategy()
|
java.lang.String |
getSpecifiedName()
|
Table |
getTable()
Return the table for this entity, either specified or default. |
boolean |
isRoot()
Return whether this entity is a root entity in an inheritance hierarchy. |
void |
moveSpecifiedPrimaryKeyJoinColumn(int targetIndex,
int sourceIndex)
|
void |
moveSpecifiedSecondaryTable(int targetIndex,
int sourceIndex)
Move the specified secondary table from the source index to the target index. |
java.util.ListIterator<? extends ReadOnlyPrimaryKeyJoinColumn> |
primaryKeyJoinColumns()
|
int |
primaryKeyJoinColumnsSize()
|
void |
removeSpecifiedPrimaryKeyJoinColumn(int index)
|
void |
removeSpecifiedPrimaryKeyJoinColumn(PrimaryKeyJoinColumn primaryKeyJoinColumn)
|
void |
removeSpecifiedSecondaryTable(int index)
Remove the specified secondary table from the entity. |
void |
removeSpecifiedSecondaryTable(SecondaryTable secondaryTable)
Remove the specified secondary table at the index from the entity. |
AttributeMapping |
resolveAttributeMapping(java.lang.String name)
Returns the attribute mapping that matches the name. |
java.util.ListIterator<? extends ReadOnlySecondaryTable> |
secondaryTables()
Return the secondary tables whether specified or default. |
int |
secondaryTablesSize()
Return the number of secondary tables, both specified and default. |
void |
setSpecifiedDiscriminatorValue(java.lang.String value)
|
void |
setSpecifiedInheritanceStrategy(InheritanceType inheritanceType)
|
void |
setSpecifiedName(java.lang.String name)
|
boolean |
specifiedDiscriminatorColumnIsAllowed()
Return whether a DiscriminatorColumn is allowed for this Entity. |
boolean |
specifiedDiscriminatorValueIsAllowed()
Return whether a DiscriminatorValue is allowed for this Entity. |
java.util.ListIterator<? extends PrimaryKeyJoinColumn> |
specifiedPrimaryKeyJoinColumns()
|
int |
specifiedPrimaryKeyJoinColumnsSize()
|
java.util.ListIterator<? extends SecondaryTable> |
specifiedSecondaryTables()
Return a list iterator of the specified secondary tables. |
int |
specifiedSecondaryTablesSize()
Return the number of specified secondary tables. |
boolean |
specifiedTableIsAllowed()
Return whether a Table is allowed for this Entity. |
boolean |
tableIsUndefined()
Return whether a Table is undefined for this Entity. |
| Methods inherited from interface org.eclipse.jpt.jpa.core.context.JpaContextNode |
|---|
getContextDefaultDbCatalog, getContextDefaultDbSchema, getContextDefaultDbSchemaContainer, getMappingFileRoot, getPersistenceUnit, getResourceType, synchronizeWithResourceModel, update |
| Methods inherited from interface org.eclipse.jpt.jpa.core.JpaNode |
|---|
getJpaProject, getParent, stateChanged |
| Methods inherited from interface org.eclipse.jpt.common.utility.model.Model |
|---|
addChangeListener, addCollectionChangeListener, addListChangeListener, addPropertyChangeListener, addStateChangeListener, addTreeChangeListener, removeChangeListener, removeCollectionChangeListener, removeListChangeListener, removePropertyChangeListener, removeStateChangeListener, removeTreeChangeListener |
| Methods inherited from interface org.eclipse.core.runtime.IAdaptable |
|---|
getAdapter |
| Methods inherited from interface org.eclipse.jpt.common.core.IResourcePart |
|---|
getResource |
| Field Detail |
|---|
static final java.lang.String SPECIFIED_NAME_PROPERTY
static final java.lang.String DEFAULT_NAME_PROPERTY
static final java.lang.String SPECIFIED_SECONDARY_TABLES_LIST
static final java.lang.String SPECIFIED_INHERITANCE_STRATEGY_PROPERTY
static final java.lang.String DEFAULT_INHERITANCE_STRATEGY_PROPERTY
static final java.lang.String SPECIFIED_DISCRIMINATOR_VALUE_PROPERTY
static final java.lang.String DEFAULT_DISCRIMINATOR_VALUE_PROPERTY
static final java.lang.String SPECIFIED_DISCRIMINATOR_VALUE_IS_ALLOWED_PROPERTY
static final java.lang.String DISCRIMINATOR_VALUE_IS_UNDEFINED_PROPERTY
static final java.lang.String SPECIFIED_DISCRIMINATOR_COLUMN_IS_ALLOWED_PROPERTY
static final java.lang.String DISCRIMINATOR_COLUMN_IS_UNDEFINED_PROPERTY
static final java.lang.String SPECIFIED_TABLE_IS_ALLOWED_PROPERTY
static final java.lang.String TABLE_IS_UNDEFINED_PROPERTY
static final java.lang.String SPECIFIED_PRIMARY_KEY_JOIN_COLUMNS_LIST
static final java.lang.String ROOT_ENTITY_PROPERTY
static final java.lang.String DESCENDANTS_COLLECTION
| Method Detail |
|---|
java.lang.String getSpecifiedName()
void setSpecifiedName(java.lang.String name)
java.lang.String getDefaultName()
IdClassReference getIdClassReference()
Table getTable()
java.lang.String getPrimaryKeyColumnName()
java.lang.String getDefaultTableName()
java.lang.String getDefaultSchema()
java.lang.String getDefaultCatalog()
java.util.ListIterator<? extends ReadOnlySecondaryTable> secondaryTables()
int secondaryTablesSize()
java.util.ListIterator<? extends SecondaryTable> specifiedSecondaryTables()
int specifiedSecondaryTablesSize()
SecondaryTable addSpecifiedSecondaryTable()
SecondaryTable addSpecifiedSecondaryTable(int index)
void removeSpecifiedSecondaryTable(int index)
void removeSpecifiedSecondaryTable(SecondaryTable secondaryTable)
void moveSpecifiedSecondaryTable(int targetIndex,
int sourceIndex)
InheritanceType getInheritanceStrategy()
InheritanceType getSpecifiedInheritanceStrategy()
void setSpecifiedInheritanceStrategy(InheritanceType inheritanceType)
InheritanceType getDefaultInheritanceStrategy()
Entity getParentEntity()
DiscriminatorColumn getDiscriminatorColumn()
java.lang.String getDiscriminatorValue()
java.lang.String getSpecifiedDiscriminatorValue()
void setSpecifiedDiscriminatorValue(java.lang.String value)
java.lang.String getDefaultDiscriminatorValue()
boolean specifiedDiscriminatorValueIsAllowed()
boolean discriminatorValueIsUndefined()
boolean specifiedDiscriminatorColumnIsAllowed()
boolean discriminatorColumnIsUndefined()
boolean specifiedTableIsAllowed()
boolean tableIsUndefined()
java.util.ListIterator<? extends ReadOnlyPrimaryKeyJoinColumn> primaryKeyJoinColumns()
int primaryKeyJoinColumnsSize()
java.util.ListIterator<? extends PrimaryKeyJoinColumn> specifiedPrimaryKeyJoinColumns()
int specifiedPrimaryKeyJoinColumnsSize()
PrimaryKeyJoinColumn addSpecifiedPrimaryKeyJoinColumn(int index)
PrimaryKeyJoinColumn addSpecifiedPrimaryKeyJoinColumn()
void removeSpecifiedPrimaryKeyJoinColumn(int index)
void removeSpecifiedPrimaryKeyJoinColumn(PrimaryKeyJoinColumn primaryKeyJoinColumn)
void moveSpecifiedPrimaryKeyJoinColumn(int targetIndex,
int sourceIndex)
AttributeOverrideContainer getAttributeOverrideContainer()
AssociationOverrideContainer getAssociationOverrideContainer()
QueryContainer getQueryContainer()
GeneratorContainer getGeneratorContainer()
boolean isRoot()
Entity getRootEntity()
null. The root
is defined as the persistent type in the inheritance hierarchy
that has no parent. The root will be an entity.
Non-entities in the hierarchy should be ignored; i.e. we skip over them in the search for the root.
java.lang.Iterable<Entity> getDescendants()
NB: An entity A is a "descendant" of another root
entity B if the name of entity A's root entity's type matches
the name of entity B's type. This means entity A can be a "descendant"
of multiple root entities (typically both the orm.xml
and Java root entities for a particular type); despite entity have only
a single "root" entity (typically the orm.xml root entity).
AttributeMapping resolveAttributeMapping(java.lang.String name)
PersistentAttribute getIdAttribute()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||