Class AbstractAuxiliaryDatabaseObject
- java.lang.Object
-
- org.hibernate.boot.model.relational.AbstractAuxiliaryDatabaseObject
-
- All Implemented Interfaces:
Serializable
,AuxiliaryDatabaseObject
,AuxiliaryDatabaseObject.Expandable
,Exportable
- Direct Known Subclasses:
SimpleAuxiliaryDatabaseObject
public abstract class AbstractAuxiliaryDatabaseObject extends Object implements AuxiliaryDatabaseObject, AuxiliaryDatabaseObject.Expandable
Convenience base class forAuxiliaryDatabaseObject
s.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 protected
AbstractAuxiliaryDatabaseObject()
AbstractAuxiliaryDatabaseObject(boolean beforeTables)
protected
AbstractAuxiliaryDatabaseObject(boolean beforeTables, Set<String> dialectScopes)
protected
AbstractAuxiliaryDatabaseObject(Set<String> dialectScopes)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addDialectScope(String dialectName)
boolean
appliesToDialect(Dialect dialect)
Does this database object apply to the given dialect?boolean
beforeTablesOnCreation()
Defines a simple precedence.Set<String>
getDialectScopes()
String
getExportIdentifier()
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, sqlDropStrings
-
-
-
-
Method Detail
-
getExportIdentifier
public String getExportIdentifier()
Description copied from interface:Exportable
Get a unique identifier to make sure we are not exporting the same database structure multiple times.- Specified by:
getExportIdentifier
in interfaceExportable
- Returns:
- The exporting identifier.
-
addDialectScope
public void addDialectScope(String dialectName)
- Specified by:
addDialectScope
in interfaceAuxiliaryDatabaseObject.Expandable
-
appliesToDialect
public boolean appliesToDialect(Dialect dialect)
Description copied from interface:AuxiliaryDatabaseObject
Does this database object apply to the given dialect?- Specified by:
appliesToDialect
in 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:AuxiliaryDatabaseObject
Defines a simple precedence. Should creation of this auxiliary object happen before creation of tables?- If
true
, the auxiliary object creation will happen after any explicit schema creation but before creation of tables and sequences. - If
false
, the auxiliary object creation will happen after explicit schema creation and after creation of tables and sequences.
This precedence is automatically inverted for when the schema is dropped.
- Specified by:
beforeTablesOnCreation
in interfaceAuxiliaryDatabaseObject
- Returns:
true
indicates this object should be created before tables;false
indicates it should be created after tables.
- If
-
-