Interface MappingFieldElement
-
- All Superinterfaces:
Comparable,MappingElement,MappingElementProperties,MappingMemberElement
- All Known Subinterfaces:
MappingRelationshipElement
- All Known Implementing Classes:
MappingFieldElementImpl,MappingRelationshipElementImpl
public interface MappingFieldElement extends MappingMemberElement
- Version:
- %I%
- Author:
- raccah
-
-
Field Summary
Fields Modifier and Type Field Description static intGROUP_DEFAULTConstant representing the jdo default fetch group.static intGROUP_INDEPENDENTConstant representing an independent fetch group.static intGROUP_NONEConstant representing no fetch group.-
Fields inherited from interface com.sun.jdo.api.persistence.model.mapping.MappingElementProperties
PROP_ASSOCIATED_COLUMNS, PROP_COLUMNS, PROP_CONSISTENCY, PROP_DATABASE_ROOT, PROP_FETCH_GROUP, PROP_FIELDS, PROP_IN_CONCURRENCY_CHECK, PROP_KEY_COLUMNS, PROP_MODIFIED, PROP_NAME, PROP_NAVIGABLE, PROP_READ_ONLY, PROP_REFERENCING_KEYS, PROP_TABLE, PROP_TABLES, PROP_VERSION_FIELD
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddColumn(org.netbeans.modules.dbschema.DBMemberElement column)Adds a column to the list of columns mapped by this mapping field.ArrayListgetColumns()Returns the list of column names to which this mapping field is mapped.intgetFetchGroup()Get the fetch group of this field element.booleanisInConcurrencyCheck()Determines whether this field element is in a concurrency check or not.booleanisReadOnly()Determines whether this field element is read only or not.booleanisVersion()Determines whether this field element is a version field or not.voidremoveColumn(String columnName)Removes a column from the list of columns mapped by this mapping field.voidsetFetchGroup(int group)Set the fetch group of this field element.voidsetInConcurrencyCheck(boolean flag)Set whether this field element is in a concurrency check or not.voidsetReadOnly(boolean flag)Set whether this field element is read only or not.voidsetVersion(boolean flag)Set whether this field element is a version field or not.-
Methods inherited from interface java.lang.Comparable
compareTo
-
Methods inherited from interface com.sun.jdo.api.persistence.model.mapping.MappingElement
addPropertyChangeListener, addVetoableChangeListener, getName, removePropertyChangeListener, removeVetoableChangeListener, setName
-
Methods inherited from interface com.sun.jdo.api.persistence.model.mapping.MappingMemberElement
getDeclaringClass
-
-
-
-
Field Detail
-
GROUP_DEFAULT
static final int GROUP_DEFAULT
Constant representing the jdo default fetch group. This is what used to be mandatory for SynerJ.- See Also:
- Constant Field Values
-
GROUP_NONE
static final int GROUP_NONE
Constant representing no fetch group.- See Also:
- Constant Field Values
-
GROUP_INDEPENDENT
static final int GROUP_INDEPENDENT
Constant representing an independent fetch group. All independent fetch groups must have a value less than or equal to this constant.- See Also:
- Constant Field Values
-
-
Method Detail
-
isReadOnly
boolean isReadOnly()
Determines whether this field element is read only or not.- Returns:
trueif the field is read only,falseotherwise
-
setReadOnly
void setReadOnly(boolean flag) throws ModelExceptionSet whether this field element is read only or not.- Parameters:
flag- - iftrue, the field element is marked as read only; otherwise, it is not- Throws:
ModelException- if impossible
-
isInConcurrencyCheck
boolean isInConcurrencyCheck()
Determines whether this field element is in a concurrency check or not.- Returns:
trueif the field is in a concurrency check,falseotherwise
-
setInConcurrencyCheck
void setInConcurrencyCheck(boolean flag) throws ModelExceptionSet whether this field element is in a concurrency check or not.- Parameters:
flag- - iftrue, the field element is marked as being in a concurrency check; otherwise, it is not- Throws:
ModelException- if impossible
-
isVersion
boolean isVersion()
Determines whether this field element is a version field or not.- Returns:
trueif the field is a version field,falseotherwise
-
setVersion
void setVersion(boolean flag) throws ModelExceptionSet whether this field element is a version field or not.- Parameters:
flag- - iftrue, the field element is marked as a version field; otherwise, it is not- Throws:
ModelException- if impossible
-
getFetchGroup
int getFetchGroup()
Get the fetch group of this field element.- Returns:
- the fetch group, one of
GROUP_DEFAULT,GROUP_NONE, or anything less than or equal toGROUP_INDEPENDENT
-
setFetchGroup
void setFetchGroup(int group) throws ModelExceptionSet the fetch group of this field element.- Parameters:
group- - an integer indicating the fetch group, one of:GROUP_DEFAULT,GROUP_NONE, or anything less than or equal toGROUP_INDEPENDENT- Throws:
ModelException- if impossible
-
getColumns
ArrayList getColumns()
Returns the list of column names to which this mapping field is mapped.- Returns:
- the names of the columns mapped by this mapping field
-
addColumn
void addColumn(org.netbeans.modules.dbschema.DBMemberElement column) throws ModelExceptionAdds a column to the list of columns mapped by this mapping field.- Parameters:
column- column element to be added to the mapping- Throws:
ModelException- if impossible
-
removeColumn
void removeColumn(String columnName) throws ModelException
Removes a column from the list of columns mapped by this mapping field.- Parameters:
columnName- the relative name of the column to be removed from the mapping- Throws:
ModelException- if impossible
-
-