Class AbstractAuxiliaryDatabaseObject
- java.lang.Object
-
- org.hibernate.boot.model.relational.AbstractAuxiliaryDatabaseObject
-
- All Implemented Interfaces:
java.io.Serializable,AuxiliaryDatabaseObject,AuxiliaryDatabaseObject.Expandable,Exportable
- Direct Known Subclasses:
SimpleAuxiliaryDatabaseObject
public abstract class AbstractAuxiliaryDatabaseObject extends java.lang.Object implements AuxiliaryDatabaseObject, AuxiliaryDatabaseObject.Expandable
Convenience base class forAuxiliaryDatabaseObjects. This implementation performs dialect scoping checks strictly based on dialect name comparisons. Custom implementations might want to do instanceof-type checks.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.hibernate.boot.model.relational.AuxiliaryDatabaseObject
AuxiliaryDatabaseObject.Expandable
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractAuxiliaryDatabaseObject()AbstractAuxiliaryDatabaseObject(boolean beforeTables)protectedAbstractAuxiliaryDatabaseObject(boolean beforeTables, java.util.Set<java.lang.String> dialectScopes)protectedAbstractAuxiliaryDatabaseObject(java.util.Set<java.lang.String> dialectScopes)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddDialectScope(java.lang.String dialectName)booleanappliesToDialect(Dialect dialect)Does this database object apply to the given dialect?booleanbeforeTablesOnCreation()Defines a simple precedence.java.util.SetgetDialectScopes()java.lang.StringgetExportIdentifier()Get a unique identifier to make sure we are not exporting the same database structure multiple times.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.hibernate.boot.model.relational.AuxiliaryDatabaseObject
sqlCreateStrings, sqlCreateStrings, sqlDropStrings, sqlDropStrings
-
-
-
-
Constructor Detail
-
AbstractAuxiliaryDatabaseObject
protected AbstractAuxiliaryDatabaseObject()
-
AbstractAuxiliaryDatabaseObject
public AbstractAuxiliaryDatabaseObject(boolean beforeTables)
-
AbstractAuxiliaryDatabaseObject
protected AbstractAuxiliaryDatabaseObject(java.util.Set<java.lang.String> dialectScopes)
-
AbstractAuxiliaryDatabaseObject
protected AbstractAuxiliaryDatabaseObject(boolean beforeTables, java.util.Set<java.lang.String> dialectScopes)
-
-
Method Detail
-
getExportIdentifier
public java.lang.String getExportIdentifier()
Description copied from interface:ExportableGet a unique identifier to make sure we are not exporting the same database structure multiple times.- Specified by:
getExportIdentifierin interfaceExportable- Returns:
- The exporting identifier.
-
addDialectScope
public void addDialectScope(java.lang.String dialectName)
- Specified by:
addDialectScopein interfaceAuxiliaryDatabaseObject.Expandable
-
getDialectScopes
public java.util.Set getDialectScopes()
-
appliesToDialect
public boolean appliesToDialect(Dialect dialect)
Description copied from interface:AuxiliaryDatabaseObjectDoes this database object apply to the given dialect?- Specified by:
appliesToDialectin interfaceAuxiliaryDatabaseObject- Parameters:
dialect- The dialect to check against.- Returns:
- True if this database object does apply to the given dialect.
-
beforeTablesOnCreation
public boolean beforeTablesOnCreation()
Description copied from interface:AuxiliaryDatabaseObjectDefines a simple precedence. Should creation of this auxiliary object happen before creation of tables? Iftrue, the auxiliary object creation will happen after any explicit schema creations but before table/sequence creations; iffalse, the auxiliary object creation will happen after explicit schema creations and after table/sequence creations. This precedence is automatically inverted for dropping.- Specified by:
beforeTablesOnCreationin interfaceAuxiliaryDatabaseObject- Returns:
trueindicates this object should be created before tables;falseindicates it should be created after.
-
-