Class TemporaryTableDialect
- java.lang.Object
-
- com.evolveum.midpoint.repo.sql.util.TemporaryTableDialect
-
public abstract class TemporaryTableDialect extends Object
Created by Viliam Repan (lazyman).
-
-
Constructor Summary
Constructors Constructor Description TemporaryTableDialect()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
dropTemporaryTableAfterUse()
Do we need to drop the temporary table after use?String
generateTemporaryTableName(String baseTableName)
Generate a temporary table name given the base table.String
getCreateTemporaryTablePostfix()
Get any fragments needing to be postfixed to the command for temporary table creation.String
getCreateTemporaryTableString()
Command used to create a temporary table.String
getDropTemporaryTableString()
Command used to drop a temporary table.static @NotNull TemporaryTableDialect
getTempTableDialect(SqlRepositoryConfiguration.Database database)
Returns instance ofTemporaryTableDialect
or throws, never returns null.
-
-
-
Method Detail
-
generateTemporaryTableName
public String generateTemporaryTableName(String baseTableName)
Generate a temporary table name given the base table.- Parameters:
baseTableName
- The table name from which to base the temp table name.- Returns:
- The generated temp table name.
-
getCreateTemporaryTableString
public String getCreateTemporaryTableString()
Command used to create a temporary table.- Returns:
- The command used to create a temporary table.
-
getCreateTemporaryTablePostfix
public String getCreateTemporaryTablePostfix()
Get any fragments needing to be postfixed to the command for temporary table creation.- Returns:
- Any required postfix.
-
getDropTemporaryTableString
public String getDropTemporaryTableString()
Command used to drop a temporary table.- Returns:
- The command used to drop a temporary table.
-
dropTemporaryTableAfterUse
public boolean dropTemporaryTableAfterUse()
Do we need to drop the temporary table after use?- Returns:
- True if the table should be dropped.
-
getTempTableDialect
@NotNull public static @NotNull TemporaryTableDialect getTempTableDialect(@NotNull SqlRepositoryConfiguration.Database database)
Returns instance ofTemporaryTableDialect
or throws, never returns null.- Throws:
SystemException
- if temporary tables are not supported
-
-