Package org.hibernate.engine.query.spi
Class AbstractParameterDescriptor<T>
- java.lang.Object
-
- org.hibernate.engine.query.spi.AbstractParameterDescriptor<T>
-
- All Implemented Interfaces:
Parameter<T>
,QueryParameter<T>
- Direct Known Subclasses:
NamedParameterDescriptor
,OrdinalParameterDescriptor
@Incubating public abstract class AbstractParameterDescriptor<T> extends Object implements QueryParameter<T>
- API Note:
- Consider this contract (and its subcontracts) as incubating as we transition to 6.0 and SQM.
-
-
Constructor Summary
Constructors Constructor Description AbstractParameterDescriptor(int[] sourceLocations, BindableType<T> expectedType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
allowsMultiValuedBinding()
Does this parameter allow multi-valued (collection, array, etc) binding?BindableType<T>
getExpectedType()
BindableType<T>
getHibernateType()
Get the Hibernate Type associated with this parameter, if one.String
getName()
Class<T>
getParameterType()
Integer
getPosition()
void
resetExpectedType(BindableType<T> expectedType)
-
-
-
Constructor Detail
-
AbstractParameterDescriptor
public AbstractParameterDescriptor(int[] sourceLocations, BindableType<T> expectedType)
-
-
Method Detail
-
getPosition
public Integer getPosition()
- Specified by:
getPosition
in interfaceParameter<T>
-
getParameterType
public Class<T> getParameterType()
- Specified by:
getParameterType
in interfaceParameter<T>
-
getHibernateType
public BindableType<T> getHibernateType()
Description copied from interface:QueryParameter
Get the Hibernate Type associated with this parameter, if one. May returnnull
.- Specified by:
getHibernateType
in interfaceQueryParameter<T>
- Returns:
- The associated Hibernate Type, may be
null
.
-
getExpectedType
public BindableType<T> getExpectedType()
-
resetExpectedType
public void resetExpectedType(BindableType<T> expectedType)
-
allowsMultiValuedBinding
public boolean allowsMultiValuedBinding()
Description copied from interface:QueryParameter
Does this parameter allow multi-valued (collection, array, etc) binding?This is only valid for HQL/JPQL and (I think) Criteria queries, and is determined based on the context of the parameters declaration.
- Specified by:
allowsMultiValuedBinding
in interfaceQueryParameter<T>
- Returns:
true
indicates that multi-valued binding is allowed for this parameter
-
-