Package org.apache.openjpa.jdbc.meta
Class MappingDefaultsImpl
java.lang.Object
org.apache.openjpa.jdbc.meta.MappingDefaultsImpl
- All Implemented Interfaces:
MappingDefaults
,Configurable
- Direct Known Subclasses:
PersistenceMappingDefaults
Default implementation of
MappingDefaults
.- Author:
- Abe White
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
areAllPrimaryKeyColumns
(Column[] cols) Return whether all the given columns are primary key columns.protected void
correctName
(Table table, Column col) Correct the given column's name.boolean
Whether to fill in missing mapping information at runtime with the default values supplied by this plugin.void
Invoked upon completion of bean property configuration for this object.boolean
Whether to add a synthetic null indicator column to embedded mappings by default.Default base class strategy alias.Deprecated.boolean
Whether to defer constraints by default.Deprecated.Default discriminator strategy alias.getDiscriminatorValue
(Discriminator disc, boolean adapt) Provides a default value for the given Discriminator.getFieldStrategy
(String valueType) Association of a field value type name with the handler or strategy class name.getForeignKey
(ValueMapping vm, String name, Table local, Table foreign, boolean inverse) Deprecated.getForeignKey
(ValueMapping vm, DBIdentifier name, Table local, Table foreign, boolean inverse) Return a default foreign key for the join from this value to its related type, or null for a logical foreign key only.int
Default foreign key action for relation keys.getIndex
(Discriminator disc, Table table, Column[] cols) Return a default index for the discriminator, or null if the discriminator columns should not be indexed by default.getIndex
(ValueMapping vm, String name, Table table, Column[] cols) Deprecated.getIndex
(ValueMapping vm, DBIdentifier name, Table table, Column[] cols) Return a default index for the value, or null if the value columns should not be indexed by default.Return a default index for the version, or null if the version columns should not be indexed by default.boolean
Whether to index discriminator columns by default.boolean
Whether to index logical foreign keys by default.protected String
getIndexName
(String name, Table table, Column[] cols) Deprecated.protected DBIdentifier
getIndexName
(DBIdentifier name, Table table, Column[] cols) boolean
Whether to use DbDictionary specific index on real foreign keys by default.boolean
Whether to index version columns by default.getJoinForeignKey
(ClassMapping cls, Table local, Table foreign) Return a default foreign key for the join from this class' table to its superclass' table, or null for a logical foreign key only.getJoinForeignKey
(FieldMapping fm, Table local, Table foreign) Return a default foreign key for the join from this field's table to its defining class' table, or null for a logical foreign key only.int
Default foreign key action for join keys.getJoinIndex
(FieldMapping fm, Table table, Column[] cols) Return a default index for the join, or null if the join columns should not be indexed by default.getJoinUnique
(FieldMapping fm, Table table, Column[] cols) Return a default constraint for the join, or null if the join columns should not be constrained by default.Deprecated.Deprecated.boolean
Whether to order lists and arrays using a dedicated ordering column by default.getPrimaryKeyIdentifier
(ClassMapping cm, Table table) Return the name of the primary key for the table of the given class, or null for database default.getPrimaryKeyName
(ClassMapping cm, Table table) Deprecated.boolean
Whether to store enums as the ordinal value rather than the enum name.boolean
Whether to store a relation to an unmapped class by stringifying the oid of the related object, rather than storing primary key values.getStrategy
(ClassMapping cls, boolean adapt) Default mapping strategy when there is no explicit strategy and no hierarchy strategy given.getStrategy
(Discriminator disc, boolean adapt) Default discriminator mapping strategy when there is no explicit strategy.getStrategy
(ValueMapping vm, Class<?> type, boolean adapt) Custom handler or strategy for the given field, or null if none has been registered.getStrategy
(Version vers, boolean adapt) Default version mapping strategy when there is no explicit strategy.Default subclass strategy alias.getTableIdentifier
(ClassMapping cls, Schema schema) Return the default table name for the given class.getTableIdentifier
(FieldMapping fm, Schema schema) Return the default secondary table name for the given field.getTableName
(ClassMapping cls, Schema schema) Return the default table name for the given class.getTableName
(FieldMapping fm, Schema schema) Return the default secondary table name for the given field.getUnique
(ValueMapping vm, String name, Table table, Column[] cols) Deprecated.getUnique
(ValueMapping vm, DBIdentifier name, Table table, Column[] cols) Return a default constraint for the value, or null if the value columns should not be constrained by default.Deprecated.Default version strategy alias.void
installPrimaryKey
(FieldMapping fm, Table table) If desired, install a primary key on the given secondary table.boolean
void
populateColumns
(Discriminator disc, Table table, Column[] cols) Fill in default information for the given discriminator columns.void
populateColumns
(ValueMapping vm, String name, Table table, Column[] cols) Fill in default information for the given value columns.void
populateColumns
(ValueMapping vm, DBIdentifier name, Table table, Column[] cols) Fill in default information for the given value columns.void
populateColumns
(Version vers, Table table, Column[] cols) Fill in default information for the given version columns.void
populateDataStoreIdColumns
(ClassMapping cls, Table table, Column[] cols) Fill in default information for the given datastore identity columns.void
populateForeignKeyColumn
(ValueMapping vm, String name, Table local, Table foreign, Column col, Object target, boolean inverse, int pos, int cols) Deprecated.void
populateForeignKeyColumn
(ValueMapping vm, DBIdentifier name, Table local, Table foreign, Column col, Object target, boolean inverse, int pos, int cols) Fill in default information for the given column used to join a value to its related type.void
populateJoinColumn
(ClassMapping cm, Table local, Table foreign, Column col, Object target, int pos, int cols) Fill in default information for the given column used to join a class to its superclass table.void
populateJoinColumn
(FieldMapping fm, Table local, Table foreign, Column col, Object target, int pos, int cols) Fill in default information for the given column used to join a field to its defining class' table.boolean
populateNullIndicatorColumns
(ValueMapping vm, String name, Table table, Column[] cols) Deprecated.boolean
populateNullIndicatorColumns
(ValueMapping vm, DBIdentifier name, Table table, Column[] cols) Fill in default information for the given null indicator columns.boolean
populateOrderColumns
(FieldMapping fm, Table table, Column[] cols) Fill in default information for the given order columns.protected String
removeHungarianNotation
(String columnName) void
setAddNullIndicator
(boolean addNullInd) Whether to add a synthetic null indicator column to embedded mappings by default.void
setBaseClassStrategy
(String baseClassStrategy) Default base class strategy alias.void
Invoked prior to setting bean properties.void
setDataStoreIdColumnIdentifier
(DBIdentifier dsIdName) void
setDataStoreIdColumnName
(String dsIdName) Deprecated.void
setDefaultMissingInfo
(boolean defMissing) void
setDeferConstraints
(boolean defer) Whether to defer constraints by default.void
setDiscriminatorColumnIdentifier
(DBIdentifier discName) void
setDiscriminatorColumnName
(String discName) Deprecated.void
setDiscriminatorStrategy
(String discStrategy) Default discriminator strategy alias.void
setFieldStrategies
(String fieldMapString) Property string mapping field type names to value handler or field mapping class names.void
setFieldStrategy
(String valueType, String handlerType) Association of a field value type name with the handler or strategy class name.void
setForeignKeyDeleteAction
(int fkAction) Default foreign key action for relation keys.void
setForeignKeyDeleteAction
(String fkAction) Default foreign key action name for relation keys.void
setIndexDiscriminator
(boolean indexDisc) Whether to index discriminator columns by default.void
setIndexLogicalForeignKeys
(boolean indexFK) Whether to index logical foreign keys by default.void
setIndexPhysicalForeignKeys
(boolean indexPhysFKCompat) Whether to use DbDictionary specific index on real foreign keys by default.void
setIndexVersion
(boolean indexVers) Whether to index version columns by default.void
setJoinForeignKeyDeleteAction
(int joinFKAction) Default foreign key action for join keys.void
setJoinForeignKeyDeleteAction
(String joinFKAction) Default foreign key action name for join keys.void
setNullIndicatorColumnIdentifier
(DBIdentifier nullIndName) void
setNullIndicatorColumnName
(String nullIndName) Deprecated.void
setOrderColumnIdentifier
(DBIdentifier orderName) void
setOrderColumnName
(String orderName) Deprecated.void
setOrderLists
(boolean orderLists) Whether to order lists and arrays using a dedicated ordering column by default.void
setRemoveHungarianNotation
(boolean removeHungarianNotation) void
setStoreEnumOrdinal
(boolean ordinal) Whether to store enums as the ordinal value rather than the enum name.void
setStoreUnmappedObjectIdString
(boolean stringify) Whether to store a relation to an unmapped class by stringifying the oid of the related object, rather than storing primary key values.void
setSubclassStrategy
(String subclassStrategy) Default subclass strategy alias.void
setUseClassCriteria
(boolean classCriteria) void
setVersionColumnIdentifier
(DBIdentifier versName) void
setVersionColumnName
(String versName) Deprecated.void
setVersionStrategy
(String versionStrategy) Default version strategy alias.void
Invoked before bean property configuration is begun on this object.boolean
The default for whether relations use the related object's expected class as part of the join criteria.
-
Field Details
-
dict
-
-
Constructor Details
-
MappingDefaultsImpl
public MappingDefaultsImpl()
-
-
Method Details
-
isRemoveHungarianNotation
public boolean isRemoveHungarianNotation() -
setRemoveHungarianNotation
public void setRemoveHungarianNotation(boolean removeHungarianNotation) -
getBaseClassStrategy
Default base class strategy alias. -
setBaseClassStrategy
Default base class strategy alias. -
getSubclassStrategy
Default subclass strategy alias. -
setSubclassStrategy
Default subclass strategy alias. -
getVersionStrategy
Default version strategy alias. -
setVersionStrategy
Default version strategy alias. -
getDiscriminatorStrategy
Default discriminator strategy alias. -
setDiscriminatorStrategy
Default discriminator strategy alias. -
setFieldStrategies
Property string mapping field type names to value handler or field mapping class names. For auto-configuration. -
setFieldStrategy
Association of a field value type name with the handler or strategy class name. -
getFieldStrategy
Association of a field value type name with the handler or strategy class name. -
getStoreEnumOrdinal
public boolean getStoreEnumOrdinal()Whether to store enums as the ordinal value rather than the enum name. Defaults to false. -
setStoreEnumOrdinal
public void setStoreEnumOrdinal(boolean ordinal) Whether to store enums as the ordinal value rather than the enum name. Defaults to false. -
getStoreUnmappedObjectIdString
public boolean getStoreUnmappedObjectIdString()Whether to store a relation to an unmapped class by stringifying the oid of the related object, rather than storing primary key values. -
setStoreUnmappedObjectIdString
public void setStoreUnmappedObjectIdString(boolean stringify) Whether to store a relation to an unmapped class by stringifying the oid of the related object, rather than storing primary key values. -
getJoinForeignKeyDeleteAction
public int getJoinForeignKeyDeleteAction()Default foreign key action for join keys. Defaults to logical keys. -
setJoinForeignKeyDeleteAction
public void setJoinForeignKeyDeleteAction(int joinFKAction) Default foreign key action for join keys. Defaults to logical keys. -
setJoinForeignKeyDeleteAction
Default foreign key action name for join keys. Used in auto configuration. -
getForeignKeyDeleteAction
public int getForeignKeyDeleteAction()Default foreign key action for relation keys. Defaults to logical keys. -
setForeignKeyDeleteAction
public void setForeignKeyDeleteAction(int fkAction) Default foreign key action for relation keys. Defaults to logical keys. -
setForeignKeyDeleteAction
Default foreign key action name for relation keys. Used in auto configuration. -
getIndexLogicalForeignKeys
public boolean getIndexLogicalForeignKeys()Whether to index logical foreign keys by default. Defaults to true. -
setIndexLogicalForeignKeys
public void setIndexLogicalForeignKeys(boolean indexFK) Whether to index logical foreign keys by default. Defaults to true. -
getIndexPhysicalForeignKeys
public boolean getIndexPhysicalForeignKeys()Whether to use DbDictionary specific index on real foreign keys by default. Defaults to false i.e. old compatibility behaviour (i.e. no foreign key indices for FKs) -
setIndexPhysicalForeignKeys
public void setIndexPhysicalForeignKeys(boolean indexPhysFKCompat) Whether to use DbDictionary specific index on real foreign keys by default. Defaults to false i.e. old compatibility behaviour (i.e. no foreign key indices for FKs) -
getIndexDiscriminator
public boolean getIndexDiscriminator()Whether to index discriminator columns by default. Defaults to true. -
setIndexDiscriminator
public void setIndexDiscriminator(boolean indexDisc) Whether to index discriminator columns by default. Defaults to true. -
getIndexVersion
public boolean getIndexVersion()Whether to index version columns by default. Defaults to true. -
setIndexVersion
public void setIndexVersion(boolean indexVers) Whether to index version columns by default. Defaults to true. -
getOrderLists
public boolean getOrderLists()Whether to order lists and arrays using a dedicated ordering column by default. -
setOrderLists
public void setOrderLists(boolean orderLists) Whether to order lists and arrays using a dedicated ordering column by default. -
getAddNullIndicator
public boolean getAddNullIndicator()Whether to add a synthetic null indicator column to embedded mappings by default. -
setAddNullIndicator
public void setAddNullIndicator(boolean addNullInd) Whether to add a synthetic null indicator column to embedded mappings by default. -
getDeferConstraints
public boolean getDeferConstraints()Whether to defer constraints by default. Defaults to false. -
setDeferConstraints
public void setDeferConstraints(boolean defer) Whether to defer constraints by default. Defaults to false. -
getDataStoreIdColumnName
Deprecated.Default base name for datastore identity columns, or null to the mapping's built-in name. -
getDataStoreIdColumnIdentifier
-
setDataStoreIdColumnName
Deprecated.Default base name for datastore identity columns, or null to the mapping's built-in name. -
setDataStoreIdColumnIdentifier
-
getVersionColumnName
Deprecated.Default base name for version identity columns, or null to the mapping's built-in name. -
getVersionColumnIdentifier
-
setVersionColumnName
Deprecated.Default base name for version identity columns, or null to the mapping's built-in name. -
setVersionColumnIdentifier
-
getDiscriminatorColumnName
Deprecated.Default base name for discriminator columns, or null to the mapping's built-in name. -
getDiscriminatorColumnIdentifier
-
setDiscriminatorColumnName
Deprecated.Default base name for discriminator columns, or null to the mapping's built-in name. -
setDiscriminatorColumnIdentifier
-
getOrderColumnName
Deprecated.Default base name for order columns, or null to the mapping's built-in name. -
getOrderColumnIdentifier
-
setOrderColumnName
Deprecated.Default base name for order columns, or null to the mapping's built-in name. -
setOrderColumnIdentifier
-
getNullIndicatorColumnName
Deprecated.Default base name for null indicator columns, or null to the mapping's built-in name. -
getNullIndicatorColumnIdentifier
-
setNullIndicatorColumnName
Deprecated.Default base name for null indicator columns, or null to the mapping's built-in name. -
setNullIndicatorColumnIdentifier
-
defaultMissingInfo
public boolean defaultMissingInfo()Description copied from interface:MappingDefaults
Whether to fill in missing mapping information at runtime with the default values supplied by this plugin. A value of false means that all mapping information must be present at runtime.- Specified by:
defaultMissingInfo
in interfaceMappingDefaults
-
setDefaultMissingInfo
public void setDefaultMissingInfo(boolean defMissing) -
useClassCriteria
public boolean useClassCriteria()Description copied from interface:MappingDefaults
The default for whether relations use the related object's expected class as part of the join criteria.- Specified by:
useClassCriteria
in interfaceMappingDefaults
-
setUseClassCriteria
public void setUseClassCriteria(boolean classCriteria) -
getStrategy
Description copied from interface:MappingDefaults
Default mapping strategy when there is no explicit strategy and no hierarchy strategy given.- Specified by:
getStrategy
in interfaceMappingDefaults
- Parameters:
cls
- the class; will not be mapped, but superclass and rawMappingInfo
will be availableadapt
- whether we can adapt the mapping or schema- Returns:
- the strategy alias or a strategy instance, or null
-
getStrategy
Description copied from interface:MappingDefaults
Default version mapping strategy when there is no explicit strategy.- Specified by:
getStrategy
in interfaceMappingDefaults
- Parameters:
vers
- the version; will not be mapped, but rawMappingInfo
will be availableadapt
- whether we can adapt the mapping or schema- Returns:
- the strategy alias or a strategy instance, or null
-
getStrategy
Description copied from interface:MappingDefaults
Default discriminator mapping strategy when there is no explicit strategy.- Specified by:
getStrategy
in interfaceMappingDefaults
- Parameters:
disc
- the discriminator; will not be mapped, but rawMappingInfo
will be availableadapt
- whether we can adapt the mapping or schema- Returns:
- the strategy alias or a strategy instance, or null
-
getStrategy
Description copied from interface:MappingDefaults
Custom handler or strategy for the given field, or null if none has been registered.- Specified by:
getStrategy
in interfaceMappingDefaults
- Parameters:
vm
- the value mapping; will not be mapped, but rawMappingInfo
will be availabletype
- the value typeadapt
- whether we can adapt the mapping or schema- Returns:
- the handler/strategy alias or instance, or null
-
getDiscriminatorValue
Provides a default value for the given Discriminator.The type of the object returned relies on the javaType field being set on the Discriminator which is provided.
JavaType Default value JavaTypes.INT
The hashcode of the entity name JavaTypes.CHAR
The first character of the entity name JavaTypes.STRING
The entity name - Specified by:
getDiscriminatorValue
in interfaceMappingDefaults
- Parameters:
disc
- The discriminator that needs a default valueadapt
-- Returns:
- A new object containing the generated Discriminator value.
-
getTableName
Description copied from interface:MappingDefaults
Return the default table name for the given class. This method is only called for classes mapped to their own table.- Specified by:
getTableName
in interfaceMappingDefaults
-
getTableIdentifier
Description copied from interface:MappingDefaults
Return the default table name for the given class. This method is only called for classes mapped to their own table.- Specified by:
getTableIdentifier
in interfaceMappingDefaults
-
getTableName
Description copied from interface:MappingDefaults
Return the default secondary table name for the given field. This method is only called for fields whose strategy requires a secondary table.- Specified by:
getTableName
in interfaceMappingDefaults
-
getTableIdentifier
Description copied from interface:MappingDefaults
Return the default secondary table name for the given field. This method is only called for fields whose strategy requires a secondary table.- Specified by:
getTableIdentifier
in interfaceMappingDefaults
-
populateDataStoreIdColumns
Description copied from interface:MappingDefaults
Fill in default information for the given datastore identity columns. The columns' name and Java type will already be populated with generic defaults that may be replaced.- Specified by:
populateDataStoreIdColumns
in interfaceMappingDefaults
-
correctName
Correct the given column's name. -
removeHungarianNotation
-
populateColumns
Description copied from interface:MappingDefaults
Fill in default information for the given version columns. The columns' name and Java type will already be populated with generic defaults that may be replaced.- Specified by:
populateColumns
in interfaceMappingDefaults
-
populateColumns
Description copied from interface:MappingDefaults
Fill in default information for the given discriminator columns. The columns' name and Java type will already be populated with generic defaults that may be replaced.- Specified by:
populateColumns
in interfaceMappingDefaults
-
populateJoinColumn
public void populateJoinColumn(ClassMapping cm, Table local, Table foreign, Column col, Object target, int pos, int cols) Description copied from interface:MappingDefaults
Fill in default information for the given column used to join a class to its superclass table. The column will be a clone of the target column, or have its name and Java type set in the case of a constant target.- Specified by:
populateJoinColumn
in interfaceMappingDefaults
target
- the target of this column in the join; may be another column or a constant valuepos
- the index of this column in the logical foreign keycols
- the number of columns in the logical foreign key
-
populateJoinColumn
public void populateJoinColumn(FieldMapping fm, Table local, Table foreign, Column col, Object target, int pos, int cols) Description copied from interface:MappingDefaults
Fill in default information for the given column used to join a field to its defining class' table. The column will be a clone of the target column, or have its name and Java type set in the case of a constant target.- Specified by:
populateJoinColumn
in interfaceMappingDefaults
target
- the target of this column in the join; may be another column or a constant valuepos
- the index of this column in the logical foreign keycols
- the number of columns in the logical foreign key
-
populateForeignKeyColumn
@Deprecated public void populateForeignKeyColumn(ValueMapping vm, String name, Table local, Table foreign, Column col, Object target, boolean inverse, int pos, int cols) Deprecated.Description copied from interface:MappingDefaults
Fill in default information for the given column used to join a value to its related type. The column will be a clone of the target column, or have its name and Java type set in the case of a constant target.- Specified by:
populateForeignKeyColumn
in interfaceMappingDefaults
name
- base name for value, as decided by mappingtarget
- the target of this column in the join; may be another column or a constant valueinverse
- whether this is an inverse foreign keypos
- the index of this column in the logical foreign keycols
- the number of columns in the logical foreign key
-
populateForeignKeyColumn
public void populateForeignKeyColumn(ValueMapping vm, DBIdentifier name, Table local, Table foreign, Column col, Object target, boolean inverse, int pos, int cols) Description copied from interface:MappingDefaults
Fill in default information for the given column used to join a value to its related type. The column will be a clone of the target column, or have its name and Java type set in the case of a constant target.- Specified by:
populateForeignKeyColumn
in interfaceMappingDefaults
name
- base name for value, as decided by mappingtarget
- the target of this column in the join; may be another column or a constant valueinverse
- whether this is an inverse foreign keypos
- the index of this column in the logical foreign keycols
- the number of columns in the logical foreign key
-
populateColumns
Description copied from interface:MappingDefaults
Fill in default information for the given value columns. The columns' name and Java type will already be populated with generic defaults that may be replaced.- Specified by:
populateColumns
in interfaceMappingDefaults
name
- base name for value, as decided by mapping
-
populateColumns
Description copied from interface:MappingDefaults
Fill in default information for the given value columns. The columns' name and Java type will already be populated with generic defaults that may be replaced.- Specified by:
populateColumns
in interfaceMappingDefaults
name
- base name for value, as decided by mapping
-
populateOrderColumns
Description copied from interface:MappingDefaults
Fill in default information for the given order columns. The columns' name and Java type will already be populated with generic defaults that may be replaced.- Specified by:
populateOrderColumns
in interfaceMappingDefaults
- Returns:
- false if the given field should not have order columns by default; fill in default information even when returning false in case the user forces ordering
-
populateNullIndicatorColumns
@Deprecated public boolean populateNullIndicatorColumns(ValueMapping vm, String name, Table table, Column[] cols) Deprecated.Description copied from interface:MappingDefaults
Fill in default information for the given null indicator columns. The columns' name and Java type will already be populated with generic defaults that may be replaced.- Specified by:
populateNullIndicatorColumns
in interfaceMappingDefaults
name
- base name for value, as decided by mapping- Returns:
- false if the given value should not have null indicator columns by default; fill in default information even when returning false in case the user forces an indicator
-
populateNullIndicatorColumns
public boolean populateNullIndicatorColumns(ValueMapping vm, DBIdentifier name, Table table, Column[] cols) Description copied from interface:MappingDefaults
Fill in default information for the given null indicator columns. The columns' name and Java type will already be populated with generic defaults that may be replaced.- Specified by:
populateNullIndicatorColumns
in interfaceMappingDefaults
name
- base name for value, as decided by mapping- Returns:
- false if the given value should not have null indicator columns by default; fill in default information even when returning false in case the user forces an indicator
-
getJoinForeignKey
Description copied from interface:MappingDefaults
Return a default foreign key for the join from this class' table to its superclass' table, or null for a logical foreign key only. Do not add columns to the key or add the key to the table; only fill in its information such as name, delete action, etc.- Specified by:
getJoinForeignKey
in interfaceMappingDefaults
-
getJoinForeignKey
Description copied from interface:MappingDefaults
Return a default foreign key for the join from this field's table to its defining class' table, or null for a logical foreign key only. Do not add columns to the key or add the key to the table; only fill in its information such as name, delete action, etc.- Specified by:
getJoinForeignKey
in interfaceMappingDefaults
-
getForeignKey
@Deprecated public ForeignKey getForeignKey(ValueMapping vm, String name, Table local, Table foreign, boolean inverse) Deprecated.Description copied from interface:MappingDefaults
Return a default foreign key for the join from this value to its related type, or null for a logical foreign key only. Do not add columns to the key or add the key to the table; only fill in its information such as name, delete action, etc.- Specified by:
getForeignKey
in interfaceMappingDefaults
name
- base name for value, as decided by mappinginverse
- whether this is an inverse key
-
getForeignKey
public ForeignKey getForeignKey(ValueMapping vm, DBIdentifier name, Table local, Table foreign, boolean inverse) Description copied from interface:MappingDefaults
Return a default foreign key for the join from this value to its related type, or null for a logical foreign key only. Do not add columns to the key or add the key to the table; only fill in its information such as name, delete action, etc.- Specified by:
getForeignKey
in interfaceMappingDefaults
name
- base name for value, as decided by mappinginverse
- whether this is an inverse key
-
getJoinIndex
Description copied from interface:MappingDefaults
Return a default index for the join, or null if the join columns should not be indexed by default. Do not add columns to the index or add the index to the table; only fill in its information such as name, uniqueness, etc.- Specified by:
getJoinIndex
in interfaceMappingDefaults
-
areAllPrimaryKeyColumns
Return whether all the given columns are primary key columns. -
getIndexName
Deprecated.Generate an index name. -
getIndexName
-
getIndex
Deprecated.Description copied from interface:MappingDefaults
Return a default index for the value, or null if the value columns should not be indexed by default. Do not add columns to the index or add the index to the table; only fill in its information such as name, uniqueness, etc.- Specified by:
getIndex
in interfaceMappingDefaults
name
- base name for value, as decided by mapping
-
getIndex
Description copied from interface:MappingDefaults
Return a default index for the value, or null if the value columns should not be indexed by default. Do not add columns to the index or add the index to the table; only fill in its information such as name, uniqueness, etc.- Specified by:
getIndex
in interfaceMappingDefaults
name
- base name for value, as decided by mapping
-
getIndex
Description copied from interface:MappingDefaults
Return a default index for the version, or null if the version columns should not be indexed by default. Do not add columns to the index or add the index to the table; only fill in its information such as name, uniqueness, etc.- Specified by:
getIndex
in interfaceMappingDefaults
-
getIndex
Description copied from interface:MappingDefaults
Return a default index for the discriminator, or null if the discriminator columns should not be indexed by default. Do not add columns to the index or add the index to the table; only fill in its information such as name, uniqueness, etc.- Specified by:
getIndex
in interfaceMappingDefaults
-
getJoinUnique
Description copied from interface:MappingDefaults
Return a default constraint for the join, or null if the join columns should not be constrained by default. Do not add columns to the constraint or add the constraint to the table; only fill in its information such as name, deferrability, etc.- Specified by:
getJoinUnique
in interfaceMappingDefaults
-
getUnique
Deprecated.Description copied from interface:MappingDefaults
Return a default constraint for the value, or null if the value columns should not be constrained by default. Do not add columns to the constraint or add the constraint to the table; only fill in its information such as name, deferrability, etc.- Specified by:
getUnique
in interfaceMappingDefaults
name
- base name for value, as decided by mapping
-
getUnique
Description copied from interface:MappingDefaults
Return a default constraint for the value, or null if the value columns should not be constrained by default. Do not add columns to the constraint or add the constraint to the table; only fill in its information such as name, deferrability, etc.- Specified by:
getUnique
in interfaceMappingDefaults
name
- base name for value, as decided by mapping
-
getPrimaryKeyName
Deprecated.Description copied from interface:MappingDefaults
Return the name of the primary key for the table of the given class, or null for database default.- Specified by:
getPrimaryKeyName
in interfaceMappingDefaults
-
getPrimaryKeyIdentifier
Description copied from interface:MappingDefaults
Return the name of the primary key for the table of the given class, or null for database default.- Specified by:
getPrimaryKeyIdentifier
in interfaceMappingDefaults
-
installPrimaryKey
Description copied from interface:MappingDefaults
If desired, install a primary key on the given secondary table.- Specified by:
installPrimaryKey
in interfaceMappingDefaults
-
setConfiguration
Description copied from interface:Configurable
Invoked prior to setting bean properties.- Specified by:
setConfiguration
in interfaceConfigurable
-
startConfiguration
public void startConfiguration()Description copied from interface:Configurable
Invoked before bean property configuration is begun on this object.- Specified by:
startConfiguration
in interfaceConfigurable
-
endConfiguration
public void endConfiguration()Description copied from interface:Configurable
Invoked upon completion of bean property configuration for this object.- Specified by:
endConfiguration
in interfaceConfigurable
-