org.apache.ignite.internal.jdbc.thin

## Class JdbcThinUtils

- java.lang.Object
- - org.apache.ignite.internal.jdbc.thin.JdbcThinUtils

    public class JdbcThinUtils
    extends Object

Utility methods for thin JDBC driver.

### Field Summary

Fields
`static int` `DFLT_PORT` Default port.
`static String` `PARAM_AUTO_CLOSE_SERVER_CURSOR` Parameter: Automatically close server cursor.
`static String` `PARAM_COLLOCATED` Parameter: collocated flag.
`static String` `PARAM_DISTRIBUTED_JOINS` Parameter: distributed joins flag.
`static String` `PARAM_ENFORCE_JOIN_ORDER` Parameter: enforce join order flag.
`static String` `PARAM_REPLICATED_ONLY` Parameter: replicated only flag.
`static String` `PARAM_SOCK_RCV_BUF` Parameter: socket receive buffer.
`static String` `PARAM_SOCK_SND_BUF` Parameter: socket send buffer.
`static String` `PARAM_TCP_NO_DELAY` Parameter: TCP no-delay flag.
`static String` `PROP_AUTO_CLOSE_SERVER_CURSORS` Automatically close server cursor.
`static String` `PROP_COLLOCATED` Collocated property name.
`static String` `PROP_DISTRIBUTED_JOINS` Distributed joins property name.
`static String` `PROP_ENFORCE_JOIN_ORDER` Transactions allowed property name.
`static String` `PROP_HOST` Hostname property name.
`static String` `PROP_PORT` Port number property name.
`static String` `PROP_PREFIX` Prefix for property names.
`static String` `PROP_REPLICATED_ONLY` Replicated only property name.
`static String` `PROP_SOCK_RCV_BUF` Socket receive buffer property name.
`static String` `PROP_SOCK_SND_BUF` Socket send buffer property name.
`static String` `PROP_TCP_NO_DELAY` TCP no delay property name.
`static String` `URL_PREFIX` URL prefix.

### Constructor Summary

Constructors
Constructor and Description
`JdbcThinUtils()`

### Method Summary

Methods
`static boolean` `isPlainJdbcType(int type)`
`static boolean` `nullable(String name, String cls)` Determines whether type is nullable.
`static String` `trimPrefix(String prop)` Trim prefix from property.
`static int` `type(String cls)` Converts Java class name to type from `Types`.
`static String` `typeName(String cls)` Converts Java class name to SQL type name.

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

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

### Field Detail

#### URL_PREFIX

    public static final String URL_PREFIX

URL prefix.

See Also:
  Constant Field Values

#### PROP_PREFIX

    public static final String PROP_PREFIX

Prefix for property names.

See Also:
  Constant Field Values

#### PROP_PORT

    public static final String PROP_PORT

Port number property name.

See Also:
  Constant Field Values

#### PROP_HOST

    public static final String PROP_HOST

Hostname property name.

See Also:
  Constant Field Values

#### PARAM_DISTRIBUTED_JOINS

    public static final String PARAM_DISTRIBUTED_JOINS

Parameter: distributed joins flag.

See Also:
  Constant Field Values

#### PARAM_ENFORCE_JOIN_ORDER

    public static final String PARAM_ENFORCE_JOIN_ORDER

Parameter: enforce join order flag.

See Also:
  Constant Field Values

#### PARAM_COLLOCATED

    public static final String PARAM_COLLOCATED

Parameter: collocated flag.

See Also:
  Constant Field Values

#### PARAM_REPLICATED_ONLY

    public static final String PARAM_REPLICATED_ONLY

Parameter: replicated only flag.

See Also:
  Constant Field Values

#### PARAM_SOCK_SND_BUF

    public static final String PARAM_SOCK_SND_BUF

Parameter: socket send buffer.

See Also:
  Constant Field Values

#### PARAM_SOCK_RCV_BUF

    public static final String PARAM_SOCK_RCV_BUF

Parameter: socket receive buffer.

See Also:
  Constant Field Values

#### PARAM_TCP_NO_DELAY

    public static final String PARAM_TCP_NO_DELAY

Parameter: TCP no-delay flag.

See Also:
  Constant Field Values

#### PARAM_AUTO_CLOSE_SERVER_CURSOR

    public static final String PARAM_AUTO_CLOSE_SERVER_CURSOR

Parameter: Automatically close server cursor.

See Also:
  Constant Field Values

#### PROP_DISTRIBUTED_JOINS

    public static final String PROP_DISTRIBUTED_JOINS

Distributed joins property name.

See Also:
  Constant Field Values

#### PROP_ENFORCE_JOIN_ORDER

    public static final String PROP_ENFORCE_JOIN_ORDER

Transactions allowed property name.

See Also:
  Constant Field Values

#### PROP_COLLOCATED

    public static final String PROP_COLLOCATED

Collocated property name.

See Also:
  Constant Field Values

#### PROP_REPLICATED_ONLY

    public static final String PROP_REPLICATED_ONLY

Replicated only property name.

See Also:
  Constant Field Values

#### PROP_SOCK_SND_BUF

    public static final String PROP_SOCK_SND_BUF

Socket send buffer property name.

See Also:
  Constant Field Values

#### PROP_SOCK_RCV_BUF

    public static final String PROP_SOCK_RCV_BUF

Socket receive buffer property name.

See Also:
  Constant Field Values

#### PROP_TCP_NO_DELAY

    public static final String PROP_TCP_NO_DELAY

TCP no delay property name.

See Also:
  Constant Field Values

#### PROP_AUTO_CLOSE_SERVER_CURSORS

    public static final String PROP_AUTO_CLOSE_SERVER_CURSORS

Automatically close server cursor.

See Also:
  Constant Field Values

#### DFLT_PORT

    public static final int DFLT_PORT

Default port.

See Also:
  Constant Field Values

### Constructor Detail

#### JdbcThinUtils

    public JdbcThinUtils()

### Method Detail

#### trimPrefix

    public static String trimPrefix(String prop)

Trim prefix from property.

Parameters:
  `prop` - Property.
Returns:
  Parameter name.

#### type

    public static int type(String cls)

Converts Java class name to type from `Types`.

Parameters:
  `cls` - Java class name.
Returns:
  Type from `Types`.

#### typeName

    public static String typeName(String cls)

Converts Java class name to SQL type name.

Parameters:
  `cls` - Java class name.
Returns:
  SQL type name.

#### isPlainJdbcType

    public static boolean isPlainJdbcType(int type)

Parameters:
  `type` - a value from `java.sql.Types`.
Returns:
  `true` if type is plain and supported by thin JDBC driver.

#### nullable

    public static boolean nullable(String name,
                   String cls)

Determines whether type is nullable.

Parameters:
  `name` - Column name.
  `cls` - Java class name.
Returns:
  `True` if nullable.

2017 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Fabric | : ver. 2.2.0
Release Date | : September 15 2017