Top Description Fields Constructors Methods
com.google.gson.internal.sql

public final Class SqlTypesSupport

extends Object
Class Inheritance
Annotations
@SuppressWarnings:JavaUtilDate
Imports
com.google.gson.TypeAdapterFactory, com.google.gson.internal.bind.DefaultDateTypeAdapter.DateType, java.sql.Timestamp, java.util.Arrays, .Collections, .Date, .List

Encapsulates access to java.sql types, to allow Gson to work without the java.sql module being present. No ClassNotFoundExceptions will be thrown in case the java.sql module is not present.

If SUPPORTS_SQL_TYPES is true, all other constants of this class will be non-null and SQL_TYPE_FACTORIES will contain the SQL type adapter factories. However, if it is false all other constants will be null and SQL_TYPE_FACTORIES will be an empty list, and there will be no support for java.sql types.

Field Summary

Modifier and TypeField and Description
public static final DefaultDateTypeAdapter.DateType<? extends Date>
public static final TypeAdapterFactory
public static final List<TypeAdapterFactory>
public static final boolean
SUPPORTS_SQL_TYPES

true if java.sql types are supported, false otherwise

public static final TypeAdapterFactory
public static final DefaultDateTypeAdapter.DateType<? extends Date>
public static final TypeAdapterFactory

Constructor Summary

AccessConstructor and Description
private

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

DATE_DATE_TYPEback to summary
public static final DefaultDateTypeAdapter.DateType<? extends Date> DATE_DATE_TYPE
DATE_FACTORYback to summary
public static final TypeAdapterFactory DATE_FACTORY
SQL_TYPE_FACTORIESback to summary
public static final List<TypeAdapterFactory> SQL_TYPE_FACTORIES
SUPPORTS_SQL_TYPESback to summary
public static final boolean SUPPORTS_SQL_TYPES

true if java.sql types are supported, false otherwise

TIME_FACTORYback to summary
public static final TypeAdapterFactory TIME_FACTORY
TIMESTAMP_DATE_TYPEback to summary
public static final DefaultDateTypeAdapter.DateType<? extends Date> TIMESTAMP_DATE_TYPE
TIMESTAMP_FACTORYback to summary
public static final TypeAdapterFactory TIMESTAMP_FACTORY

Constructor Detail

SqlTypesSupportback to summary
private SqlTypesSupport()