From f81847111565021502cb291518c91daeb2390737 Mon Sep 17 00:00:00 2001 From: Steve Ebersole Date: Fri, 13 Aug 2010 16:32:46 +0000 Subject: [PATCH] HHH-5477 - Introduce StandardBasicTypes for standard basic type constants git-svn-id: https://svn.jboss.org/repos/hibernate/core/trunk@20138 1b8cb986-b30d-0410-93ca-fae66ebed9b2 --- .../main/java/org/hibernate/Hibernate.java | 161 ++++----- .../java/org/hibernate/type/BinaryType.java | 2 +- .../org/hibernate/type/SerializableType.java | 8 + .../hibernate/type/StandardBasicTypes.java | 313 ++++++++++++++++++ 4 files changed, 403 insertions(+), 81 deletions(-) create mode 100644 core/src/main/java/org/hibernate/type/StandardBasicTypes.java diff --git a/core/src/main/java/org/hibernate/Hibernate.java b/core/src/main/java/org/hibernate/Hibernate.java index e09673ad93..7fea791475 100644 --- a/core/src/main/java/org/hibernate/Hibernate.java +++ b/core/src/main/java/org/hibernate/Hibernate.java @@ -106,172 +106,173 @@ public final class Hibernate { private Hibernate() { throw new UnsupportedOperationException(); } - - /** - * Hibernate long type. - * @deprecated Use {@link LongType#INSTANCE} instead. - */ - public static final LongType LONG = LongType.INSTANCE; - /** - * Hibernate short type. - * @deprecated Use {@link ShortType#INSTANCE} instead. - */ - public static final ShortType SHORT = ShortType.INSTANCE; - /** - * Hibernate integer type. - * @deprecated Use {@link IntegerType#INSTANCE} instead. - */ - public static final IntegerType INTEGER = IntegerType.INSTANCE; - /** - * Hibernate byte type. - * @deprecated Use {@link ByteType#INSTANCE} instead. - */ - public static final ByteType BYTE = ByteType.INSTANCE; - /** - * Hibernate float type. - * @deprecated Use {@link FloatType#INSTANCE} instead. - */ - public static final FloatType FLOAT = FloatType.INSTANCE; - /** - * Hibernate double type. - * @deprecated Use {@link DoubleType#INSTANCE} instead. - */ - public static final DoubleType DOUBLE = DoubleType.INSTANCE; - /** - * Hibernate character type. - * @deprecated Use {@link CharacterType#INSTANCE} instead. - */ - public static final CharacterType CHARACTER = CharacterType.INSTANCE; - /** - * Hibernate string type. - * @deprecated Use {@link StringType#INSTANCE} instead. - */ - public static final StringType STRING = StringType.INSTANCE; - /** - * Hibernate time type. - * @deprecated Use {@link TimeType#INSTANCE} instead. - */ - public static final TimeType TIME = TimeType.INSTANCE; - /** - * Hibernate date type. - * @deprecated Use {@link DateType#INSTANCE} instead. - */ - public static final DateType DATE = DateType.INSTANCE; - /** - * Hibernate timestamp type. - * @deprecated Use {@link TimestampType#INSTANCE} instead. - */ - public static final TimestampType TIMESTAMP = TimestampType.INSTANCE; /** * Hibernate boolean type. - * @deprecated Use {@link BooleanType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#BOOLEAN} instead. */ public static final BooleanType BOOLEAN = BooleanType.INSTANCE; /** * Hibernate true_false type. - * @deprecated Use {@link TrueFalseType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#TRUE_FALSE} instead. */ public static final TrueFalseType TRUE_FALSE = TrueFalseType.INSTANCE; /** * Hibernate yes_no type. - * @deprecated Use {@link YesNoType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#YES_NO} instead. */ public static final YesNoType YES_NO = YesNoType.INSTANCE; /** - * Hibernate big_decimal type. - * @deprecated Use {@link BigDecimalType#INSTANCE} instead. + * Hibernate byte type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#BYTE} instead. */ - public static final BigDecimalType BIG_DECIMAL = BigDecimalType.INSTANCE; + public static final ByteType BYTE = ByteType.INSTANCE; + /** + * Hibernate short type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#SHORT} instead. + */ + public static final ShortType SHORT = ShortType.INSTANCE; + /** + * Hibernate integer type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#INTEGER} instead. + */ + public static final IntegerType INTEGER = IntegerType.INSTANCE; + /** + * Hibernate long type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#LONG} instead. + */ + public static final LongType LONG = LongType.INSTANCE; + /** + * Hibernate float type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#FLOAT} instead. + */ + public static final FloatType FLOAT = FloatType.INSTANCE; + /** + * Hibernate double type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#DOUBLE} instead. + */ + public static final DoubleType DOUBLE = DoubleType.INSTANCE; /** * Hibernate big_integer type. - * @deprecated Use {@link BigIntegerType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#BIG_INTEGER} instead. */ public static final BigIntegerType BIG_INTEGER = BigIntegerType.INSTANCE; + /** + * Hibernate big_decimal type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#BIG_DECIMAL} instead. + */ + public static final BigDecimalType BIG_DECIMAL = BigDecimalType.INSTANCE; + /** + * Hibernate character type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#CHARACTER} instead. + */ + public static final CharacterType CHARACTER = CharacterType.INSTANCE; + /** + * Hibernate string type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#STRING} instead. + */ + public static final StringType STRING = StringType.INSTANCE; + /** + * Hibernate time type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#TIME} instead. + */ + public static final TimeType TIME = TimeType.INSTANCE; + /** + * Hibernate date type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#DATE} instead. + */ + public static final DateType DATE = DateType.INSTANCE; + /** + * Hibernate timestamp type. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#TIMESTAMP} instead. + */ + public static final TimestampType TIMESTAMP = TimestampType.INSTANCE; /** * Hibernate binary type. - * @deprecated Use {@link BinaryType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#BINARY} instead. */ public static final BinaryType BINARY = BinaryType.INSTANCE; /** * Hibernate wrapper-binary type. - * @deprecated Use {@link WrapperBinaryType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#WRAPPER_BINARY} instead. */ public static final WrapperBinaryType WRAPPER_BINARY = WrapperBinaryType.INSTANCE; /** * Hibernate char[] type. - * @deprecated Use {@link CharArrayType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#CHAR_ARRAY} instead. */ public static final CharArrayType CHAR_ARRAY = CharArrayType.INSTANCE; /** * Hibernate Character[] type. - * @deprecated Use {@link CharacterArrayType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#CHARACTER_ARRAY} instead. */ public static final CharacterArrayType CHARACTER_ARRAY = CharacterArrayType.INSTANCE; /** * Hibernate image type. - * @deprecated Use {@link ImageType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#IMAGE} instead. */ public static final ImageType IMAGE = ImageType.INSTANCE; /** * Hibernate text type. - * @deprecated Use {@link TextType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#TEXT} instead. */ public static final TextType TEXT = TextType.INSTANCE; /** * Hibernate materialized_blob type. - * @deprecated Use {@link MaterializedBlobType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#MATERIALIZED_BLOB} instead. */ public static final MaterializedBlobType MATERIALIZED_BLOB = MaterializedBlobType.INSTANCE; /** * Hibernate materialized_clob type. - * @deprecated Use {@link MaterializedClobType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#MATERIALIZED_CLOB} instead. */ public static final MaterializedClobType MATERIALIZED_CLOB = MaterializedClobType.INSTANCE; /** * Hibernate blob type. - * @deprecated Use {@link BlobType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#BLOB} instead. */ public static final BlobType BLOB = BlobType.INSTANCE; /** * Hibernate clob type. - * @deprecated Use {@link ClobType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#CLOB} instead. */ public static final ClobType CLOB = ClobType.INSTANCE; /** * Hibernate calendar type. - * @deprecated Use {@link CalendarType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#CALENDAR} instead. */ public static final CalendarType CALENDAR = CalendarType.INSTANCE; /** * Hibernate calendar_date type. - * @deprecated Use {@link CalendarDateType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#CALENDAR_DATE} instead. */ public static final CalendarDateType CALENDAR_DATE = CalendarDateType.INSTANCE; /** * Hibernate locale type. - * @deprecated Use {@link LocaleType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#LOCALE} instead. */ public static final LocaleType LOCALE = LocaleType.INSTANCE; /** * Hibernate currency type. - * @deprecated Use {@link CurrencyType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#CURRENCY} instead. */ public static final CurrencyType CURRENCY = CurrencyType.INSTANCE; /** * Hibernate timezone type. - * @deprecated Use {@link TimeZoneType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#TIMEZONE} instead. */ public static final TimeZoneType TIMEZONE = TimeZoneType.INSTANCE; /** * Hibernate class type. - * @deprecated Use {@link ClassType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#CLASS} instead. */ public static final ClassType CLASS = ClassType.INSTANCE; /** * Hibernate serializable type. - * @deprecated Use {@link SerializableType#INSTANCE} instead. + * @deprecated Use {@link org.hibernate.type.StandardBasicTypes#SERIALIZABLE} instead. */ public static final SerializableType SERIALIZABLE = SerializableType.INSTANCE; + + /** * Hibernate object type. * @deprecated Use {@link ObjectType#INSTANCE} instead. diff --git a/core/src/main/java/org/hibernate/type/BinaryType.java b/core/src/main/java/org/hibernate/type/BinaryType.java index 820085f65c..5a57e50b0d 100644 --- a/core/src/main/java/org/hibernate/type/BinaryType.java +++ b/core/src/main/java/org/hibernate/type/BinaryType.java @@ -30,7 +30,7 @@ import org.hibernate.type.descriptor.java.PrimitiveByteArrayTypeDescriptor; import org.hibernate.type.descriptor.sql.VarbinaryTypeDescriptor; /** - * A type that maps between a {@link java.sql.Types#NUMERIC NUMERIC} and {@code byte[]} + * A type that maps between a {@link java.sql.Types#VARBINARY VARBINARY} and {@code byte[]} * * @author Gavin King * @author Steve Ebersole diff --git a/core/src/main/java/org/hibernate/type/SerializableType.java b/core/src/main/java/org/hibernate/type/SerializableType.java index 9dbdae14d1..78bb6ed29b 100644 --- a/core/src/main/java/org/hibernate/type/SerializableType.java +++ b/core/src/main/java/org/hibernate/type/SerializableType.java @@ -30,6 +30,14 @@ import org.hibernate.type.descriptor.sql.VarbinaryTypeDescriptor; /** * A type that maps between a {@link java.sql.Types#VARBINARY VARBINARY} and {@link Serializable} classes. + *

+ * Notice specifically the 2 forms:

+ * The important distinction has to do with locating the appropriate {@link ClassLoader} to use during deserialization. + * In the fist form we are always using the {@link ClassLoader} of the JVM (Hibernate will always fallback to trying + * its classloader as well). The second form is better at targeting the needed {@link ClassLoader} actually needed. * * @author Gavin King * @author Steve Ebersole diff --git a/core/src/main/java/org/hibernate/type/StandardBasicTypes.java b/core/src/main/java/org/hibernate/type/StandardBasicTypes.java new file mode 100644 index 0000000000..5933ac517b --- /dev/null +++ b/core/src/main/java/org/hibernate/type/StandardBasicTypes.java @@ -0,0 +1,313 @@ +/* + * Hibernate, Relational Persistence for Idiomatic Java + * + * Copyright (c) 2010, Red Hat Inc. or third-party contributors as + * indicated by the @author tags or express copyright attribution + * statements applied by the authors. All third-party contributions are + * distributed under license by Red Hat Inc. + * + * This copyrighted material is made available to anyone wishing to use, modify, + * copy, or redistribute it subject to the terms and conditions of the GNU + * Lesser General Public License, as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License + * for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this distribution; if not, write to: + * Free Software Foundation, Inc. + * 51 Franklin Street, Fifth Floor + * Boston, MA 02110-1301 USA + */ +package org.hibernate.type; + +/** + * Centralizes access to the standard set of basic {@link Type types}. + *

+ * Type mappings can be adjusted per {@link org.hibernate.SessionFactory}. These adjusted mappings can be accessed + * from the {@link org.hibernate.TypeHelper} instance obtained via {@link org.hibernate.SessionFactory#getTypeHelper()} + * + * @see BasicTypeRegistry + * @see org.hibernate.TypeHelper + * @see org.hibernate.SessionFactory#getTypeHelper() + * + * @author Gavin King + * @author Steve Ebersole + */ +public class StandardBasicTypes { + /** + * The standard Hibernate type for mapping {@link Boolean} to JDBC {@link java.sql.Types#BIT BIT}. + * + * @see BooleanType + */ + public static final BooleanType BOOLEAN = BooleanType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Boolean} to JDBC {@link java.sql.Types#INTEGER INTEGER}. + * + * @see NumericBooleanType + */ + public static final NumericBooleanType NUMERIC_BOOLEAN = NumericBooleanType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Boolean} to JDBC {@link java.sql.Types#CHAR CHAR(1)} (using 'T'/'F'). + * + * @see TrueFalseType + */ + public static final TrueFalseType TRUE_FALSE = TrueFalseType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Boolean} to JDBC {@link java.sql.Types#CHAR CHAR(1)} (using 'Y'/'N'). + * + * @see YesNoType + */ + public static final YesNoType YES_NO = YesNoType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Byte} to JDBC {@link java.sql.Types#TINYINT TINYINT}. + */ + public static final ByteType BYTE = ByteType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Short} to JDBC {@link java.sql.Types#SMALLINT SMALLINT}. + * + * @see ShortType + */ + public static final ShortType SHORT = ShortType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Integer} to JDBC {@link java.sql.Types#INTEGER INTEGER}. + * + * @see IntegerType + */ + public static final IntegerType INTEGER = IntegerType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Long} to JDBC {@link java.sql.Types#BIGINT BIGINT}. + * + * @see LongType + */ + public static final LongType LONG = LongType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Float} to JDBC {@link java.sql.Types#FLOAT FLOAT}. + * + * @see FloatType + */ + public static final FloatType FLOAT = FloatType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Double} to JDBC {@link java.sql.Types#DOUBLE DOUBLE}. + * + * @see DoubleType + */ + public static final DoubleType DOUBLE = DoubleType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.math.BigInteger} to JDBC {@link java.sql.Types#NUMERIC NUMERIC}. + * + * @see BigIntegerType + */ + public static final BigIntegerType BIG_INTEGER = BigIntegerType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.math.BigDecimal} to JDBC {@link java.sql.Types#NUMERIC NUMERIC}. + * + * @see BigDecimalType + */ + public static final BigDecimalType BIG_DECIMAL = BigDecimalType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Character} to JDBC {@link java.sql.Types#CHAR CHAR(1)}. + * + * @see CharacterType + */ + public static final CharacterType CHARACTER = CharacterType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link String} to JDBC {@link java.sql.Types#VARCHAR VARCHAR}. + * + * @see StringType + */ + public static final StringType STRING = StringType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.net.URL} to JDBC {@link java.sql.Types#VARCHAR VARCHAR}. + * + * @see UrlType + */ + public static final UrlType URL = UrlType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.Date} ({@link java.sql.Time}) to JDBC + * {@link java.sql.Types#TIME TIME}. + * + * @see TimeType + */ + public static final TimeType TIME = TimeType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.Date} ({@link java.sql.Date}) to JDBC + * {@link java.sql.Types#DATE DATE}. + * + * @see TimeType + */ + public static final DateType DATE = DateType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.Date} ({@link java.sql.Timestamp}) to JDBC + * {@link java.sql.Types#TIMESTAMP TIMESTAMP}. + * + * @see TimeType + */ + public static final TimestampType TIMESTAMP = TimestampType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.Calendar} to JDBC + * {@link java.sql.Types#TIMESTAMP TIMESTAMP}. + * + * @see CalendarType + */ + public static final CalendarType CALENDAR = CalendarType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.Calendar} to JDBC + * {@link java.sql.Types#DATE DATE}. + * + * @see CalendarDateType + */ + public static final CalendarDateType CALENDAR_DATE = CalendarDateType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Class} to JDBC {@link java.sql.Types#VARCHAR VARCHAR}. + * + * @see ClassType + */ + public static final ClassType CLASS = ClassType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.Locale} to JDBC {@link java.sql.Types#VARCHAR VARCHAR}. + * + * @see LocaleType + */ + public static final LocaleType LOCALE = LocaleType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.Currency} to JDBC {@link java.sql.Types#VARCHAR VARCHAR}. + * + * @see CurrencyType + */ + public static final CurrencyType CURRENCY = CurrencyType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.TimeZone} to JDBC {@link java.sql.Types#VARCHAR VARCHAR}. + * + * @see TimeZoneType + */ + public static final TimeZoneType TIMEZONE = TimeZoneType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.UUID} to JDBC {@link java.sql.Types#BINARY BINARY}. + * + * @see UUIDBinaryType + */ + public static final UUIDBinaryType UUID_BINARY = UUIDBinaryType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.util.UUID} to JDBC {@link java.sql.Types#CHAR CHAR}. + * + * @see UUIDCharType + */ + public static final UUIDCharType UUID_CHAR = UUIDCharType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@code byte[]} to JDBC {@link java.sql.Types#VARBINARY VARBINARY}. + * + * @see BinaryType + */ + public static final BinaryType BINARY = BinaryType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Byte Byte[]} to JDBC {@link java.sql.Types#VARBINARY VARBINARY}. + * + * @see WrapperBinaryType + */ + public static final WrapperBinaryType WRAPPER_BINARY = WrapperBinaryType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@code byte[]} to JDBC {@link java.sql.Types#LONGVARBINARY LONGVARBINARY}. + * + * @see ImageType + * @see #MATERIALIZED_BLOB + */ + public static final ImageType IMAGE = ImageType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.sql.Blob} to JDBC {@link java.sql.Types#BLOB BLOB}. + * + * @see BlobType + * @see #MATERIALIZED_BLOB + */ + public static final BlobType BLOB = BlobType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@code byte[]} to JDBC {@link java.sql.Types#BLOB BLOB}. + * + * @see MaterializedBlobType + * @see #MATERIALIZED_BLOB + * @see #IMAGE + */ + public static final MaterializedBlobType MATERIALIZED_BLOB = MaterializedBlobType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@code char[]} to JDBC {@link java.sql.Types#VARCHAR VARCHAR}. + * + * @see CharArrayType + */ + public static final CharArrayType CHAR_ARRAY = CharArrayType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link Character Character[]} to JDBC + * {@link java.sql.Types#VARCHAR VARCHAR}. + * + * @see CharacterArrayType + */ + public static final CharacterArrayType CHARACTER_ARRAY = CharacterArrayType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link String} to JDBC {@link java.sql.Types#LONGVARCHAR LONGVARCHAR}. + *

+ * Similar to a {@link #MATERIALIZED_CLOB} + * + * @see TextType + */ + public static final TextType TEXT = TextType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.sql.Clob} to JDBC {@link java.sql.Types#CLOB CLOB}. + * + * @see ClobType + * @see #MATERIALIZED_CLOB + */ + public static final ClobType CLOB = ClobType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link String} to JDBC {@link java.sql.Types#CLOB CLOB}. + * + * @see MaterializedClobType + * @see #MATERIALIZED_CLOB + * @see #TEXT + */ + public static final MaterializedClobType MATERIALIZED_CLOB = MaterializedClobType.INSTANCE; + + /** + * The standard Hibernate type for mapping {@link java.io.Serializable} to JDBC {@link java.sql.Types#VARBINARY VARBINARY}. + *

+ * See especially the discussion wrt {@link ClassLoader} determination on {@link SerializableType} + * + * @see SerializableType + */ + public static final SerializableType SERIALIZABLE = SerializableType.INSTANCE; +}