Class DiscriminatorTypeImpl<O>
- java.lang.Object
-
- org.hibernate.type.internal.ConvertedBasicTypeImpl<O>
-
- org.hibernate.metamodel.mapping.internal.DiscriminatorTypeImpl<O>
-
- All Implemented Interfaces:
BasicType<O>
,Type<O>
,Serializable
,BasicValuedMapping
,Bindable
,DiscriminatorType<O>
,JdbcMapping
,JdbcMappingContainer
,MappingModelExpressible
,MappingType
,SqlExpressible
,ValueMapping
,BasicDomainType<O>
,DomainType<O>
,SimpleDomainType<O>
,BindableType<O>
,OutputableType<O>
,ReturnableType<O>
,SqmExpressible<O>
,AdjustableBasicType<O>
,BasicType<O>
,ConvertedBasicType<O>
,JavaTypedExpressible
,ProcedureParameterExtractionAware<O>
,ProcedureParameterNamedBinder<O>
,Type
public class DiscriminatorTypeImpl<O> extends ConvertedBasicTypeImpl<O> implements DiscriminatorType<O>
Specialization of ConvertedBasicTypeImpl to expose access to theunderlyingJdbcMapping
of this discriminator - the bit that handles the relationship between the relational JavaType and the JdbcType- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.hibernate.metamodel.mapping.Bindable
Bindable.JdbcValuesBiConsumer<X,Y>, Bindable.JdbcValuesConsumer
-
Nested classes/interfaces inherited from interface jakarta.persistence.metamodel.Type
Type.PersistenceType
-
-
Field Summary
-
Fields inherited from class org.hibernate.type.internal.ConvertedBasicTypeImpl
EXTERNALIZED_PREFIX, NO_REG_KEYS
-
-
Constructor Summary
Constructors Constructor Description DiscriminatorTypeImpl(BasicType<?> underlyingJdbcMapping, DiscriminatorConverter<O,?> discriminatorValueConverter)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
canDoExtraction()
Can the given instance of this type actually perform the parameter value extractions?JavaType<O>
getExpressibleJavaType()
The Java type descriptor for this expressibleClass
getJavaType()
BasicType<?>
getUnderlyingJdbcMapping()
DiscriminatorConverter
getValueConverter()
Returns the converter that this basic type uses for transforming from the domain type, to the relational type, ornull
if there is no conversion.-
Methods inherited from class org.hibernate.type.internal.ConvertedBasicTypeImpl
assemble, beforeAssemble, canDoSetting, compare, deepCopy, disassemble, disassemble, extract, extract, getCastType, getColumnSpan, getHashCode, getHashCode, getJavaTypeDescriptor, getJdbcJavaType, getJdbcLiteralFormatter, getJdbcType, getJdbcValueBinder, getJdbcValueExtractor, getMutabilityPlan, getName, getRegistrationKeys, getReturnedClass, getSqlTypeCodes, isAnyType, isAssociationType, isCollectionType, isComponentType, isDirty, isDirty, isDirty, isEntityType, isEqual, isEqual, isModified, isMutable, isSame, nullSafeSet, nullSafeSet, nullSafeSet, replace, replace, toColumnNullness, toLoggableString, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.hibernate.type.AdjustableBasicType
resolveIndicatedType
-
Methods inherited from interface org.hibernate.metamodel.model.domain.BasicDomainType
areEqual, getPersistenceType
-
Methods inherited from interface org.hibernate.type.BasicType
compare, disassemble, forEachDisassembledJdbcValue, forEachJdbcType, forEachJdbcType, getCheckCondition, getJdbcLiteralFormatter, getJdbcMapping, getJdbcMapping, getJdbcTypeCount, getJdbcValueBinder, getJdbcValueExtractor, getMappedJavaType, getMappedType, getRegistrationKeys, getSingleJdbcMapping
-
Methods inherited from interface org.hibernate.metamodel.mapping.BasicValuedMapping
addToCacheKey
-
Methods inherited from interface org.hibernate.metamodel.mapping.Bindable
forEachDisassembledJdbcValue, forEachDisassembledJdbcValue, forEachDisassembledJdbcValue, forEachJdbcValue, forEachJdbcValue, forEachJdbcValue, forEachJdbcValue
-
Methods inherited from interface org.hibernate.metamodel.mapping.DiscriminatorType
getJavaTypeDescriptor
-
Methods inherited from interface org.hibernate.metamodel.model.domain.DomainType
getSqmType, getTupleLength
-
Methods inherited from interface org.hibernate.metamodel.mapping.JdbcMapping
convertToDomainValue, convertToRelationalValue, getCastType, getJdbcJavaType, getJdbcType
-
Methods inherited from interface org.hibernate.query.OutputableType
extract, extract, getJdbcType
-
Methods inherited from interface org.hibernate.metamodel.model.domain.SimpleDomainType
getBindableJavaType
-
Methods inherited from interface org.hibernate.query.sqm.SqmExpressible
getRelationalJavaType, getTypeName, isInstance, resolveExpressible
-
Methods inherited from interface org.hibernate.type.Type
assemble, beforeAssemble, compare, deepCopy, disassemble, disassemble, getColumnSpan, getHashCode, getHashCode, getName, getReturnedClass, getReturnedClassName, getSqlTypeCodes, getTypeForEqualsHashCode, isAnyType, isAssociationType, isCollectionType, isComponentType, isDirty, isDirty, isEntityType, isEqual, isEqual, isModified, isMutable, isSame, nullSafeSet, nullSafeSet, replace, replace, toColumnNullness, toLoggableString
-
Methods inherited from interface org.hibernate.metamodel.mapping.ValueMapping
treatAs
-
-
-
-
Constructor Detail
-
DiscriminatorTypeImpl
public DiscriminatorTypeImpl(BasicType<?> underlyingJdbcMapping, DiscriminatorConverter<O,?> discriminatorValueConverter)
-
-
Method Detail
-
getUnderlyingJdbcMapping
public BasicType<?> getUnderlyingJdbcMapping()
- Specified by:
getUnderlyingJdbcMapping
in interfaceDiscriminatorType<O>
-
getValueConverter
public DiscriminatorConverter getValueConverter()
Description copied from interface:JdbcMapping
Returns the converter that this basic type uses for transforming from the domain type, to the relational type, ornull
if there is no conversion.- Specified by:
getValueConverter
in interfaceBasicType<O>
- Specified by:
getValueConverter
in interfaceConvertedBasicType<O>
- Specified by:
getValueConverter
in interfaceDiscriminatorType<O>
- Specified by:
getValueConverter
in interfaceJdbcMapping
- Overrides:
getValueConverter
in classConvertedBasicTypeImpl<O>
-
getJavaType
public Class getJavaType()
- Specified by:
getJavaType
in interfaceType<O>
- Overrides:
getJavaType
in classConvertedBasicTypeImpl<O>
-
canDoExtraction
public boolean canDoExtraction()
Description copied from interface:OutputableType
Can the given instance of this type actually perform the parameter value extractions?- Specified by:
canDoExtraction
in interfaceOutputableType<O>
- Overrides:
canDoExtraction
in classConvertedBasicTypeImpl<O>
- Returns:
true
indicates thatOutputableType.extract(java.sql.CallableStatement, int, org.hibernate.engine.spi.SharedSessionContractImplementor)
calls will not fail due toIllegalStateException
.
-
getExpressibleJavaType
public JavaType<O> getExpressibleJavaType()
Description copied from interface:SqmExpressible
The Java type descriptor for this expressible- Specified by:
getExpressibleJavaType
in interfaceBasicType<O>
- Specified by:
getExpressibleJavaType
in interfaceJavaTypedExpressible<O>
- Specified by:
getExpressibleJavaType
in interfaceSqmExpressible<O>
- Specified by:
getExpressibleJavaType
in interfaceValueMapping
-
-