Package liquibase.datatype.core
Class TimeType
- java.lang.Object
-
- liquibase.datatype.LiquibaseDataType
-
- liquibase.datatype.core.TimeType
-
- All Implemented Interfaces:
PrioritizedService
public class TimeType extends LiquibaseDataType
-
-
Field Summary
Fields Modifier and Type Field Description protected static int
MSSQL_TYPE_TIME_DEFAULT_PRECISION
static Pattern
PARENTHESIS_PATTERN
-
Fields inherited from interface liquibase.servicelocator.PrioritizedService
COMPARATOR, PRIORITY_DATABASE, PRIORITY_DEFAULT
-
-
Constructor Summary
Constructors Constructor Description TimeType()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LoadDataChange.LOAD_DATA_TYPE
getLoadTypeName()
Returns one of the four basic data types for use in LoadData: BOOLEAN, NUMERIC, DATE or STRINGprotected DateFormat
getTimeFormat(Database database)
String
objectToSql(Object value, Database database)
Returns the value object in a format to include in SQL.Object
sqlToObject(String value, Database database)
DatabaseDataType
toDatabaseDataType(Database database)
Transforms this data type into the native data type of the target DBMS.-
Methods inherited from class liquibase.datatype.LiquibaseDataType
addParameter, equals, finishInitialization, formatNumber, functionToSql, getAdditionalInformation, getAliases, getMaxParameters, getMinParameters, getName, getParameters, getPriority, getRawDefinition, hashCode, isAutoIncrement, isCurrentDateTimeFunction, numberToSql, otherToSql, setAdditionalInformation, supports, toString, validate
-
-
-
-
Field Detail
-
MSSQL_TYPE_TIME_DEFAULT_PRECISION
protected static final int MSSQL_TYPE_TIME_DEFAULT_PRECISION
- See Also:
- Constant Field Values
-
PARENTHESIS_PATTERN
public static final Pattern PARENTHESIS_PATTERN
-
-
Method Detail
-
toDatabaseDataType
public DatabaseDataType toDatabaseDataType(Database database)
Description copied from class:LiquibaseDataType
Transforms this data type into the native data type of the target DBMS.- Overrides:
toDatabaseDataType
in classLiquibaseDataType
- Parameters:
database
- theDatabase
for which the native data type is to be constructed- Returns:
- the new, native data type
-
objectToSql
public String objectToSql(Object value, Database database)
Description copied from class:LiquibaseDataType
Returns the value object in a format to include in SQL. Quote if necessary.- Overrides:
objectToSql
in classLiquibaseDataType
-
sqlToObject
public Object sqlToObject(String value, Database database)
- Overrides:
sqlToObject
in classLiquibaseDataType
-
getLoadTypeName
public LoadDataChange.LOAD_DATA_TYPE getLoadTypeName()
Description copied from class:LiquibaseDataType
Returns one of the four basic data types for use in LoadData: BOOLEAN, NUMERIC, DATE or STRING- Specified by:
getLoadTypeName
in classLiquibaseDataType
- Returns:
- one of the above Strings
-
getTimeFormat
protected DateFormat getTimeFormat(Database database)
-
-