api-docs / org.ktorm.schema / SqlType
SqlType
abstract class SqlType<T : Any>
(source code)Abstraction of SQL data types.
Based on JDBC, SqlType and its subclasses encapsulate the common operations of obtaining data from a ResultSet
and setting parameters to a PreparedStatement.
Constructors
Name | Summary |
---|---|
Abstraction of SQL data types. |
Properties
Name | Summary |
---|---|
val typeCode: Int a constant value defined in java.sql.Types to identify JDBC types. | |
val typeName: String the name of the type in specific databases, such as |
Functions
Name | Summary |
---|---|
Obtain a result from a given ResultSet by index, the result may be null. | |
abstract fun doSetParameter( Set the parameter to a given PreparedStatement, the parameter can’t be null. | |
Indicates whether some other object is “equal to” this SQL type. | |
Obtain a result from a given ResultSet by index. Obtain a result from a given ResultSet by columnLabel. | |
open fun hashCode(): Int Return a hash code value for this SQL type. | |
open fun setParameter( Set the nullable parameter to a given PreparedStatement. | |
open fun <R : Any> transform( Transform this SqlType to another. The returned SqlType has the same typeCode and typeName as the |
Companion Object Functions
Name | Summary |
---|---|
Return the corresponding ktorm core built-in SqlType for kotlin type T. |
Extension Functions
Name | Summary |
---|---|
infix fun <T : Any> T.eq( Equal operator, translated to | |
infix fun <T : Any> T.neq( Not-equal operator, translated to | |
infix fun <T : Any> T.notEq( Not-equal operator, translated to |
Inheritors
Name | Summary |
---|---|
SqlType implementation represents | |
SqlType implementation represents | |
SqlType implementation represents | |
Represents a Cube by storing 2 n-dimensional points | |
SqlType implementation represents | |
object DateTimeOffsetSqlType : SqlType<OffsetDateTime> SqlType implementation represents SQL Server | |
object DecimalSqlType : SqlType<BigDecimal> SqlType implementation represents | |
SqlType implementation represents | |
Cube-based earth abstraction, using 3 coordinates representing the x, y, and z distance from the center of the Earth. | |
SqlType implementation that saves enums as strings. | |
SqlType implementation represents | |
SqlType implementation represents PostgreSQL | |
SqlType implementation represents | |
SqlType implementation represents | |
SqlType implementation that provides JSON data type support via Jackson framework. | |
SqlType implementation represents | |
object LocalDateTimeSqlType : SqlType<LocalDateTime> SqlType implementation represents | |
SqlType implementation represents | |
SqlType implementation represents | |
SqlType implementation used to save MonthDay instances, formatting them to strings with pattern | |
SqlType implementation represents | |
SqlType implementation represents PostgreSQL | |
SqlType implementation represents | |
SqlType implementation represents | |
SqlType implementation represents | |
SqlType implementation represents | |
SqlType implementation represents | |
SqlType implementation used to save YearMonth instances, formatting them to strings with pattern | |
SqlType implementation used to save Year instances as integers. |