public class PostgreSQLEnumType
extends org.hibernate.type.EnumType
Enum to a PostgreSQL ENUM column type.
For more details about how to use it, check out this article on vladmihalcea.com.
| Modifier and Type | Field and Description |
|---|---|
static PostgreSQLEnumType |
INSTANCE |
| Constructor and Description |
|---|
PostgreSQLEnumType()
Initialization constructor taking the default
Configuration object. |
PostgreSQLEnumType(Class<? extends Enum> enumClass)
Initialization constructor taking the
Class. |
PostgreSQLEnumType(Configuration configuration)
Initialization constructor taking a custom
Configuration object. |
| Modifier and Type | Method and Description |
|---|---|
void |
nullSafeSet(PreparedStatement st,
Object value,
int index,
org.hibernate.engine.spi.SharedSessionContractImplementor session) |
int[] |
sqlTypes() |
public static final PostgreSQLEnumType INSTANCE
public PostgreSQLEnumType()
Configuration object.public PostgreSQLEnumType(Configuration configuration)
Configuration object.configuration - custom Configuration object.public void nullSafeSet(PreparedStatement st, Object value, int index, org.hibernate.engine.spi.SharedSessionContractImplementor session) throws org.hibernate.HibernateException, SQLException
nullSafeSet in interface org.hibernate.usertype.UserTypenullSafeSet in class org.hibernate.type.EnumTypeorg.hibernate.HibernateExceptionSQLExceptionpublic int[] sqlTypes()
sqlTypes in interface org.hibernate.usertype.UserTypesqlTypes in class org.hibernate.type.EnumTypeCopyright © 2024. All rights reserved.