public enum DataType extends Enum<DataType>
| 枚举常量和说明 |
|---|
BIGINT |
BINARY |
BOOL |
DOUBLE |
FLOAT |
INT |
JSON |
NCHAR |
NULL |
SMALLINT |
TIMESTAMP |
TINYINT |
UBIGINT |
UINT |
USMALLINT |
UTINYINT |
VARCHAR |
| 限定符和类型 | 方法和说明 |
|---|---|
static int |
calculateColumnSize(String typeName,
String precisionType,
int length) |
static Integer |
calculateDecimalDigits(String typeName) |
static DataType |
convertJDBC2DataType(int jdbcType) |
static DataType |
convertTaosType2DataType(int taosType) |
static DataType |
getDataType(String name) |
int |
getJdbcTypeValue() |
int |
getSize() |
int |
getTaosTypeValue() |
String |
getTypeName() |
static DataType |
valueOf(String name)
返回带有指定名称的该类型的枚举常量。
|
static DataType[] |
values()
按照声明该枚举类型的常量的顺序, 返回
包含这些常量的数组。
|
public static final DataType NULL
public static final DataType BOOL
public static final DataType TINYINT
public static final DataType UTINYINT
public static final DataType USMALLINT
public static final DataType SMALLINT
public static final DataType UINT
public static final DataType INT
public static final DataType UBIGINT
public static final DataType BIGINT
public static final DataType FLOAT
public static final DataType DOUBLE
public static final DataType BINARY
public static final DataType VARCHAR
public static final DataType TIMESTAMP
public static final DataType NCHAR
public static final DataType JSON
public static DataType[] values()
for (DataType c : DataType.values()) System.out.println(c);
public static DataType valueOf(String name)
name - 要返回的枚举常量的名称。IllegalArgumentException - 如果该枚举类型没有带有指定名称的常量NullPointerException - 如果参数为空值public String getTypeName()
public int getTaosTypeValue()
public int getJdbcTypeValue()
public int getSize()
public static DataType convertJDBC2DataType(int jdbcType) throws SQLException
SQLExceptionpublic static DataType convertTaosType2DataType(int taosType) throws SQLException
SQLExceptionpublic static int calculateColumnSize(String typeName, String precisionType, int length)
Copyright © 2022. All rights reserved.