com.taosdata.jdbc.utils

## Class DataTypeConvertUtil

- java.lang.Object
- - com.taosdata.jdbc.utils.DataTypeConvertUtil

    public class DataTypeConvertUtil
    extends Object

### Method Summary

All Methods Static Methods Concrete Methods
`static BigDecimal` `getBigDecimal(int taosType, Object value)`
`static boolean` `getBoolean(int taosType, Object value)`
`static byte` `getByte(int taosType, Object value, int columnIndex)`
`static byte[]` `getBytes(Object value)`
`static Date` `getDate(Object value, ZoneId zoneId)`
`static double` `getDouble(int taosType, Object value, int columnIndex, int timestampPrecision)`
`static float` `getFloat(int taosType, Object value, int columnIndex)`
`static int` `getInt(int taosType, Object value, int columnIndex)`
`static long` `getLong(int taosType, Object value, int columnIndex, int timestampPrecision)`
`static short` `getShort(int taosType, Object value, int columnIndex)`
`static String` `getString(Object value)`
`static Time` `getTime(Object value, ZoneId zoneId)`
`static Object` `parseValue(int type, Object source, boolean varcharAsString)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Method Detail

#### getBoolean

    public static boolean getBoolean(int taosType,
                                     Object value)
                              throws SQLDataException

Throws:
  `SQLDataException`

#### getByte

    public static byte getByte(int taosType,
                               Object value,
                               int columnIndex)
                        throws SQLException

Throws:
  `SQLException`

#### getShort

    public static short getShort(int taosType,
                                 Object value,
                                 int columnIndex)
                          throws SQLException

Throws:
  `SQLException`

#### getInt

    public static int getInt(int taosType,
                             Object value,
                             int columnIndex)
                      throws SQLException

Throws:
  `SQLException`

#### getLong

    public static long getLong(int taosType,
                               Object value,
                               int columnIndex,
                               int timestampPrecision)
                        throws SQLException

Throws:
  `SQLException`

#### getFloat

    public static float getFloat(int taosType,
                                 Object value,
                                 int columnIndex)
                          throws SQLException

Throws:
  `SQLException`

#### getDouble

    public static double getDouble(int taosType,
                                   Object value,
                                   int columnIndex,
                                   int timestampPrecision)
                            throws SQLException

Throws:
  `SQLException`

#### getBytes

    public static byte[] getBytes(Object value)
                           throws SQLException

Throws:
  `SQLException`

#### getString

    public static String getString(Object value)
                            throws SQLException

Throws:
  `SQLException`

#### getDate

    public static Date getDate(Object value,
                               ZoneId zoneId)

#### getTime

    public static Time getTime(Object value,
                               ZoneId zoneId)

#### getBigDecimal

    public static BigDecimal getBigDecimal(int taosType,
                                           Object value)

#### parseValue

    public static Object parseValue(int type,
                                    Object source,
                                    boolean varcharAsString)
                             throws SQLException

Throws:
  `SQLException`