org.h2.value

## Class ValueToObjectConverter2

- java.lang.Object
- - org.h2.message.TraceObject
  - - org.h2.value.ValueToObjectConverter2

    public final class ValueToObjectConverter2
    extends TraceObject

Data type conversion methods between values and Java objects to use on the server side on H2 only.

### Field Summary

### Fields inherited from class org.h2.message.TraceObject

`ARRAY, BLOB, CALLABLE_STATEMENT, CLOB, CONNECTION, DATA_SOURCE, DATABASE_META_DATA, PARAMETER_META_DATA, PREPARED_STATEMENT, RESULT_SET, RESULT_SET_META_DATA, SAVEPOINT, SQLXML, STATEMENT, trace, XA_DATA_SOURCE, XID`

### Method Summary

All Methods Static Methods Concrete Methods
`static TypeInfo` `classToType(java.lang.Class<?> clazz)` Get the type information for the given Java class.
`static Value` `readValue(Session session, java.sql.ResultSet rs, int columnIndex, int type)` Read a value from the given result set.

### Methods inherited from class org.h2.message.TraceObject

`debugCode, debugCodeAssign, debugCodeCall, debugCodeCall, debugCodeCall, getNextId, getTraceId, getTraceObjectName, isDebugEnabled, isInfoEnabled, logAndConvert, quote, quoteArray, quoteBigDecimal, quoteBytes, quoteDate, quoteIntArray, quoteMap, quoteTime, quoteTimestamp, setTrace, unsupported`

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

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

### Method Detail

#### classToType

    public static TypeInfo classToType(java.lang.Class<?> clazz)

Get the type information for the given Java class.

Parameters:
  `clazz` - the Java class
Returns:
  the value type

#### readValue

    public static Value readValue(Session session,
                                  java.sql.ResultSet rs,
                                  int columnIndex,
                                  int type)

Read a value from the given result set.

Parameters:
  `session` - the session
  `rs` - the result set
  `columnIndex` - the column index (1-based)
  `type` - the data type
Returns:
  the value