类 AbstractStandardBasicType<T>
- java.lang.Object
-
- org.hibernate.type.AbstractStandardBasicType<T>
-
- 所有已实现的接口:
Serializable,BasicType,ProcedureParameterExtractionAware<T>,ProcedureParameterNamedBinder,StringRepresentableType<T>,Type
public abstract class AbstractStandardBasicType<T> extends Object implements BasicType, StringRepresentableType<T>, ProcedureParameterExtractionAware<T>, ProcedureParameterNamedBinder
Convenience base class forBasicTypeimplementations- 作者:
- Steve Ebersole, Brett Meyer
- 另请参阅:
- 序列化表格
-
-
构造器概要
构造器 构造器 说明 AbstractStandardBasicType(SqlTypeDescriptor sqlTypeDescriptor, JavaTypeDescriptor<T> javaTypeDescriptor)
-
方法概要
所有方法 静态方法 实例方法 具体方法 修饰符和类型 方法 说明 Objectassemble(Serializable cached, SharedSessionContractImplementor session, Object owner)Reconstruct the object from its disassembled state.voidbeforeAssemble(Serializable cached, SharedSessionContractImplementor session)Called before assembling a query result set from the query cache, to allow batch fetching of entities missing from the second-level cache.booleancanDoExtraction()Can the given instance of this type actually perform the parameter value extractions?booleancanDoSetting()Can the given instance of this type actually set the parameter value by nameintcompare(Object x, Object y)Perform aComparatorstyle comparison between valuesObjectdeepCopy(Object value, SessionFactoryImplementor factory)Return a deep copy of the persistent state, stopping at entities and at collections.protected TdeepCopy(T value)Size[]defaultSizes(Mapping mapping)Defines the column sizes to use according to this type if the user did not explicitly say (and if noType.dictatedSizes(org.hibernate.engine.spi.Mapping)were given).Size[]dictatedSizes(Mapping mapping)Return the column sizes dictated by this type.Serializabledisassemble(Object value, SharedSessionContractImplementor session, Object owner)Return a disassembled representation of the object.Textract(CallableStatement statement, int startIndex, SharedSessionContractImplementor session)Perform the extractionTextract(CallableStatement statement, String[] paramNames, SharedSessionContractImplementor session)Perform the extractionTfromString(String string)TfromStringValue(String xml)Consume the given string representation back into this types java form.Objectget(ResultSet rs, String name, SharedSessionContractImplementor session)intgetColumnSpan(Mapping mapping)How many columns are used to persist this type.protected static SizegetDefaultSize()protected SizegetDictatedSize()intgetHashCode(Object x)Get a hash code, consistent with persistence "equality".intgetHashCode(Object x, SessionFactoryImplementor factory)Get a hash code, consistent with persistence "equality".JavaTypeDescriptor<T>getJavaTypeDescriptor()protected MutabilityPlan<T>getMutabilityPlan()String[]getRegistrationKeys()Get the names under which this type should be registered in the type registry.protected TgetReplacement(T original, T target, SharedSessionContractImplementor session)ClassgetReturnedClass()TypegetSemiResolvedType(SessionFactoryImplementor factory)As part of 2-phase loading, when we perform resolving what is the resolved type for this type?SqlTypeDescriptorgetSqlTypeDescriptor()Objecthydrate(ResultSet rs, String[] names, SharedSessionContractImplementor session, Object owner)Extract a value from the JDBC result set.booleanisAnyType()Return true if the implementation is castable toAnyType.booleanisAssociationType()Return true if the implementation is castable toAssociationType.booleanisCollectionType()Return true if the implementation is castable toCollectionType.booleanisComponentType()Return true if the implementation is castable toCompositeType.protected booleanisDirty(Object old, Object current)booleanisDirty(Object old, Object current, boolean[] checkable, SharedSessionContractImplementor session)Should the parent be considered dirty, given both the old and current value?booleanisDirty(Object old, Object current, SharedSessionContractImplementor session)Should the parent be considered dirty, given both the old and current value?booleanisEntityType()Return true if the implementation is castable toEntityType.booleanisEqual(Object one, Object another)Compare two instances of the class mapped by this type for persistence "equality" (equality of persistent state).booleanisEqual(Object x, Object y, SessionFactoryImplementor factory)Compare two instances of the class mapped by this type for persistence "equality" (equality of persistent state).booleanisModified(Object oldHydratedState, Object currentState, boolean[] checkable, SharedSessionContractImplementor session)Has the value been modified compared to the current database state?booleanisMutable()Are objects of this type mutable.booleanisSame(Object x, Object y)Compare two instances of the class mapped by this type for persistence "equality" (equality of persistent state) taking a shortcut for entity references.booleanisXMLElement()ObjectnullSafeGet(ResultSet rs, String[] names, SharedSessionContractImplementor session, Object owner)Extract a value of themapped classfrom the JDBC result set.TnullSafeGet(ResultSet rs, String name, SharedSessionContractImplementor session)ObjectnullSafeGet(ResultSet rs, String name, SharedSessionContractImplementor session, Object owner)Extract a value of themapped classfrom the JDBC result set.protected TnullSafeGet(ResultSet rs, String name, WrapperOptions options)voidnullSafeSet(CallableStatement st, Object value, String name, SharedSessionContractImplementor session)Bind a value to the JDBC prepared statement, ignoring some columns as dictated by the 'settable' parameter.protected voidnullSafeSet(CallableStatement st, Object value, String name, WrapperOptions options)voidnullSafeSet(PreparedStatement st, Object value, int index, SharedSessionContractImplementor session)Bind a value represented by an instance of themapped classto the JDBC prepared statement.protected voidnullSafeSet(PreparedStatement st, Object value, int index, WrapperOptions options)protected booleanregisterUnderJavaType()protected SqlTypeDescriptorremapSqlTypeDescriptor(WrapperOptions options)Objectreplace(Object original, Object target, SharedSessionContractImplementor session, Object owner, Map copyCache)During merge, replace the existing (target) value in the entity we are merging to with a new (original) value from the detached entity we are merging.Objectreplace(Object original, Object target, SharedSessionContractImplementor session, Object owner, Map copyCache, ForeignKeyDirection foreignKeyDirection)During merge, replace the existing (target) value in the entity we are merging to with a new (original) value from the detached entity we are merging.Objectresolve(Object value, SharedSessionContractImplementor session, Object owner)ObjectsemiResolve(Object value, SharedSessionContractImplementor session, Object owner)Given a hydrated, but unresolved value, return a value that may be used to reconstruct property-ref associations.voidset(PreparedStatement st, T value, int index, SharedSessionContractImplementor session)voidsetJavaTypeDescriptor(JavaTypeDescriptor<T> javaTypeDescriptor)voidsetSqlTypeDescriptor(SqlTypeDescriptor sqlTypeDescriptor)int[]sqlTypes(Mapping mapping)Return the JDBC types codes (perTypes) for the columns mapped by this type.boolean[]toColumnNullness(Object value, Mapping mapping)Given an instance of the type, return an array of boolean, indicating which mapped columns would be null.StringtoLoggableString(Object value, SessionFactoryImplementor factory)Generate a representation of the value for logging purposes.StringtoString(T value)Render the value to the string representation.-
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
从接口继承的方法 org.hibernate.type.Type
getName, nullSafeSet, resolve
-
-
-
-
构造器详细资料
-
AbstractStandardBasicType
public AbstractStandardBasicType(SqlTypeDescriptor sqlTypeDescriptor, JavaTypeDescriptor<T> javaTypeDescriptor)
-
-
方法详细资料
-
toString
public String toString(T value)
从接口复制的说明:StringRepresentableTypeRender the value to the string representation.- 指定者:
toString在接口中StringRepresentableType<T>- 参数:
value- The value to render to string.- 返回:
- The string representation
-
fromStringValue
public T fromStringValue(String xml) throws HibernateException
从接口复制的说明:StringRepresentableTypeConsume the given string representation back into this types java form.- 指定者:
fromStringValue在接口中StringRepresentableType<T>- 参数:
xml- The string representation to be consumed.- 返回:
- The java type representation
- 抛出:
HibernateException- Problem consuming
-
getMutabilityPlan
protected MutabilityPlan<T> getMutabilityPlan()
-
getReplacement
protected T getReplacement(T original, T target, SharedSessionContractImplementor session)
-
toColumnNullness
public boolean[] toColumnNullness(Object value, Mapping mapping)
从接口复制的说明:TypeGiven an instance of the type, return an array of boolean, indicating which mapped columns would be null.- 指定者:
toColumnNullness在接口中Type- 参数:
value- an instance of the typemapping- The mapping abstraction- 返回:
- array indicating column nullness for a value instance
-
getRegistrationKeys
public String[] getRegistrationKeys()
从接口复制的说明:BasicTypeGet the names under which this type should be registered in the type registry.- 指定者:
getRegistrationKeys在接口中BasicType- 返回:
- The keys under which to register this type.
-
registerUnderJavaType
protected boolean registerUnderJavaType()
-
getDefaultSize
protected static Size getDefaultSize()
-
getDictatedSize
protected Size getDictatedSize()
-
getJavaTypeDescriptor
public final JavaTypeDescriptor<T> getJavaTypeDescriptor()
-
setJavaTypeDescriptor
public final void setJavaTypeDescriptor(JavaTypeDescriptor<T> javaTypeDescriptor)
-
getSqlTypeDescriptor
public final SqlTypeDescriptor getSqlTypeDescriptor()
-
setSqlTypeDescriptor
public final void setSqlTypeDescriptor(SqlTypeDescriptor sqlTypeDescriptor)
-
getReturnedClass
public final Class getReturnedClass()
从接口复制的说明:TypeThe class returned byType.nullSafeGet(java.sql.ResultSet, java.lang.String[], org.hibernate.engine.spi.SharedSessionContractImplementor, java.lang.Object)methods. This is used to establish the class of an array of this type.- 指定者:
getReturnedClass在接口中Type- 返回:
- The java type class handled by this type.
-
getColumnSpan
public final int getColumnSpan(Mapping mapping) throws MappingException
从接口复制的说明:TypeHow many columns are used to persist this type. Always the same assqlTypes(mapping).length- 指定者:
getColumnSpan在接口中Type- 参数:
mapping- The mapping object :/- 返回:
- The number of columns
- 抛出:
MappingException- Generally indicates an issue accessing the passed mapping object.
-
sqlTypes
public final int[] sqlTypes(Mapping mapping) throws MappingException
从接口复制的说明:TypeReturn the JDBC types codes (perTypes) for the columns mapped by this type. NOTE: The number of elements in this array matches the return fromType.getColumnSpan(org.hibernate.engine.spi.Mapping).- 指定者:
sqlTypes在接口中Type- 参数:
mapping- The mapping object :/- 返回:
- The JDBC type codes.
- 抛出:
MappingException- Generally indicates an issue accessing the passed mapping object.
-
dictatedSizes
public Size[] dictatedSizes(Mapping mapping) throws MappingException
从接口复制的说明:TypeReturn the column sizes dictated by this type. For example, the mapping for achar/Characterwould have a dictated length limit of 1; for a string-basedUUIDwould have a size limit of 36; etc. NOTE: The number of elements in this array matches the return fromType.getColumnSpan(org.hibernate.engine.spi.Mapping).- 指定者:
dictatedSizes在接口中Type- 参数:
mapping- The mapping object :/- 返回:
- The dictated sizes.
- 抛出:
MappingException- Generally indicates an issue accessing the passed mapping object.
-
defaultSizes
public Size[] defaultSizes(Mapping mapping) throws MappingException
从接口复制的说明:TypeDefines the column sizes to use according to this type if the user did not explicitly say (and if noType.dictatedSizes(org.hibernate.engine.spi.Mapping)were given). NOTE: The number of elements in this array matches the return fromType.getColumnSpan(org.hibernate.engine.spi.Mapping).- 指定者:
defaultSizes在接口中Type- 参数:
mapping- The mapping object :/- 返回:
- The default sizes.
- 抛出:
MappingException- Generally indicates an issue accessing the passed mapping object.
-
isAssociationType
public final boolean isAssociationType()
从接口复制的说明:TypeReturn true if the implementation is castable toAssociationType. This does not necessarily imply that the type actually represents an association. Essentially a polymorphic version of(type instanceof AssociationType.class)- 指定者:
isAssociationType在接口中Type- 返回:
- True if this type is also an
AssociationTypeimplementor; false otherwise.
-
isCollectionType
public final boolean isCollectionType()
从接口复制的说明:TypeReturn true if the implementation is castable toCollectionType. Essentially a polymorphic version of(type instanceof CollectionType.class)ACollectionTypeis additionally anAssociationType; so if this method returns true,Type.isAssociationType()should also return true.- 指定者:
isCollectionType在接口中Type- 返回:
- True if this type is also a
CollectionTypeimplementor; false otherwise.
-
isComponentType
public final boolean isComponentType()
从接口复制的说明:TypeReturn true if the implementation is castable toCompositeType. Essentially a polymorphic version of(type instanceof CompositeType.class). A component type may own collections or associations and hence must provide certain extra functionality.- 指定者:
isComponentType在接口中Type- 返回:
- True if this type is also a
CompositeTypeimplementor; false otherwise.
-
isEntityType
public final boolean isEntityType()
从接口复制的说明:TypeReturn true if the implementation is castable toEntityType. Essentially a polymorphic version of(type instanceof EntityType.class). AnEntityTypeis additionally anAssociationType; so if this method returns true,Type.isAssociationType()should also return true.- 指定者:
isEntityType在接口中Type- 返回:
- True if this type is also an
EntityTypeimplementor; false otherwise.
-
isAnyType
public final boolean isAnyType()
从接口复制的说明:TypeReturn true if the implementation is castable toAnyType. Essentially a polymorphic version of(type instanceof AnyType.class). AnAnyTypeis additionally anAssociationType; so if this method returns true,Type.isAssociationType()should also return true.
-
isXMLElement
public final boolean isXMLElement()
-
isSame
public final boolean isSame(Object x, Object y)
从接口复制的说明:TypeCompare two instances of the class mapped by this type for persistence "equality" (equality of persistent state) taking a shortcut for entity references. For most types this should equate to anequalscheck on the values. For associations the implication is a bit different. For most types it is conceivable to simply delegate toType.isEqual(java.lang.Object, java.lang.Object)
-
isEqual
public final boolean isEqual(Object x, Object y, SessionFactoryImplementor factory)
从接口复制的说明:TypeCompare two instances of the class mapped by this type for persistence "equality" (equality of persistent state). This should always equate to some form of comparison of the value's internal state. As an example, for something like a date the comparison should be based on its internal "time" state based on the specific portion it is meant to represent (timestamp, date, time).
-
isEqual
public final boolean isEqual(Object one, Object another)
从接口复制的说明:TypeCompare two instances of the class mapped by this type for persistence "equality" (equality of persistent state). This should always equate to some form of comparison of the value's internal state. As an example, for something like a date the comparison should be based on its internal "time" state based on the specific portion it is meant to represent (timestamp, date, time).
-
getHashCode
public final int getHashCode(Object x)
从接口复制的说明:TypeGet a hash code, consistent with persistence "equality". Again for most types the normal usage is to delegate to the value'shashCode.- 指定者:
getHashCode在接口中Type- 参数:
x- The value for which to retrieve a hash code- 返回:
- The hash code
-
getHashCode
public final int getHashCode(Object x, SessionFactoryImplementor factory)
从接口复制的说明:TypeGet a hash code, consistent with persistence "equality". Again for most types the normal usage is to delegate to the value'shashCode.- 指定者:
getHashCode在接口中Type- 参数:
x- The value for which to retrieve a hash codefactory- The session factory- 返回:
- The hash code
-
compare
public final int compare(Object x, Object y)
从接口复制的说明:TypePerform aComparatorstyle comparison between values- 指定者:
compare在接口中Type- 参数:
x- The first valuey- The second value- 返回:
- The comparison result. See
Comparator.compare(T, T)for a discussion.
-
isDirty
public final boolean isDirty(Object old, Object current, SharedSessionContractImplementor session)
从接口复制的说明:TypeShould the parent be considered dirty, given both the old and current value?
-
isDirty
public final boolean isDirty(Object old, Object current, boolean[] checkable, SharedSessionContractImplementor session)
从接口复制的说明:TypeShould the parent be considered dirty, given both the old and current value?
-
isModified
public final boolean isModified(Object oldHydratedState, Object currentState, boolean[] checkable, SharedSessionContractImplementor session)
从接口复制的说明:TypeHas the value been modified compared to the current database state? The difference between this and theType.isDirty(java.lang.Object, java.lang.Object, org.hibernate.engine.spi.SharedSessionContractImplementor)methods is that here we need to account for "partially" built values. This is really only an issue with association types. For most type implementations it is enough to simply delegate toType.isDirty(java.lang.Object, java.lang.Object, org.hibernate.engine.spi.SharedSessionContractImplementor)here/- 指定者:
isModified在接口中Type- 参数:
oldHydratedState- the database state, in a "hydrated" form, with identifiers unresolvedcurrentState- the current state of the objectcheckable- which columns are actually checkablesession- The session from which the request originated.- 返回:
- true if the field has been modified
-
nullSafeGet
public final Object nullSafeGet(ResultSet rs, String[] names, SharedSessionContractImplementor session, Object owner) throws SQLException
从接口复制的说明:TypeExtract a value of themapped classfrom the JDBC result set. Implementors should handle possibility of null values.- 指定者:
nullSafeGet在接口中Type- 参数:
rs- The result set from which to extract value.names- the column names making up this type value (use to read from result set)session- The originating sessionowner- the parent entity- 返回:
- The extracted value
- 抛出:
SQLException- An error from the JDBC driver- 另请参阅:
alternative, 2-phase property initialization
-
nullSafeGet
public final Object nullSafeGet(ResultSet rs, String name, SharedSessionContractImplementor session, Object owner) throws SQLException
从接口复制的说明:TypeExtract a value of themapped classfrom the JDBC result set. Implementors should handle possibility of null values. This form might be called if the type is known to be a single-column type.- 指定者:
nullSafeGet在接口中Type- 参数:
rs- The result set from which to extract value.name- the column name making up this type value (use to read from result set)session- The originating sessionowner- the parent entity- 返回:
- The extracted value
- 抛出:
SQLException- An error from the JDBC driver
-
nullSafeGet
public final T nullSafeGet(ResultSet rs, String name, SharedSessionContractImplementor session) throws SQLException
- 抛出:
SQLException
-
nullSafeGet
protected final T nullSafeGet(ResultSet rs, String name, WrapperOptions options) throws SQLException
- 抛出:
SQLException
-
get
public Object get(ResultSet rs, String name, SharedSessionContractImplementor session) throws HibernateException, SQLException
-
nullSafeSet
public final void nullSafeSet(PreparedStatement st, Object value, int index, SharedSessionContractImplementor session) throws SQLException
从接口复制的说明:TypeBind a value represented by an instance of themapped classto the JDBC prepared statement. Implementors should handle possibility of null values. A multi-column type should bind parameters starting from index.- 指定者:
nullSafeSet在接口中Type- 参数:
st- The JDBC prepared statement to which to bindvalue- the object to writeindex- starting parameter bind indexsession- The originating session- 抛出:
SQLException- An error from the JDBC driver
-
nullSafeSet
protected final void nullSafeSet(PreparedStatement st, Object value, int index, WrapperOptions options) throws SQLException
- 抛出:
SQLException
-
remapSqlTypeDescriptor
protected SqlTypeDescriptor remapSqlTypeDescriptor(WrapperOptions options)
-
set
public void set(PreparedStatement st, T value, int index, SharedSessionContractImplementor session) throws HibernateException, SQLException
-
toLoggableString
public final String toLoggableString(Object value, SessionFactoryImplementor factory)
从接口复制的说明:TypeGenerate a representation of the value for logging purposes.- 指定者:
toLoggableString在接口中Type- 参数:
value- The value to be loggedfactory- The session factory- 返回:
- The loggable representation
-
isMutable
public final boolean isMutable()
从接口复制的说明:TypeAre objects of this type mutable. (With respect to the referencing object ... entities and collections are considered immutable because they manage their own internal state.)
-
deepCopy
public final Object deepCopy(Object value, SessionFactoryImplementor factory)
从接口复制的说明:TypeReturn a deep copy of the persistent state, stopping at entities and at collections.
-
disassemble
public final Serializable disassemble(Object value, SharedSessionContractImplementor session, Object owner) throws HibernateException
从接口复制的说明:TypeReturn a disassembled representation of the object. This is the value Hibernate will use in second level caching, so care should be taken to break values down to their simplest forms; for entities especially, this means breaking them down into their constituent parts.- 指定者:
disassemble在接口中Type- 参数:
value- the value to cachesession- the originating sessionowner- optional parent entity object (needed for collections)- 返回:
- the disassembled, deep cloned state
- 抛出:
HibernateException- An error from Hibernate
-
assemble
public final Object assemble(Serializable cached, SharedSessionContractImplementor session, Object owner) throws HibernateException
从接口复制的说明:TypeReconstruct the object from its disassembled state. This method is the reciprocal ofType.disassemble(java.lang.Object, org.hibernate.engine.spi.SharedSessionContractImplementor, java.lang.Object)- 指定者:
assemble在接口中Type- 参数:
cached- the disassembled state from the cachesession- the originating sessionowner- the parent entity object- 返回:
- the (re)assembled object
- 抛出:
HibernateException- An error from Hibernate
-
beforeAssemble
public final void beforeAssemble(Serializable cached, SharedSessionContractImplementor session)
从接口复制的说明:TypeCalled before assembling a query result set from the query cache, to allow batch fetching of entities missing from the second-level cache.- 指定者:
beforeAssemble在接口中Type- 参数:
cached- The keysession- The originating session
-
hydrate
public final Object hydrate(ResultSet rs, String[] names, SharedSessionContractImplementor session, Object owner) throws HibernateException, SQLException
从接口复制的说明:TypeExtract a value from the JDBC result set. This is useful for 2-phase property initialization - the second phase is a call toType.resolve(java.lang.Object, org.hibernate.engine.spi.SharedSessionContractImplementor, java.lang.Object)This hydrated value will be either:- in the case of an entity or collection type, the key
- otherwise, the value itself
- 指定者:
hydrate在接口中Type- 参数:
rs- The JDBC result setnames- the column names making up this type value (use to read from result set)session- The originating sessionowner- the parent entity- 返回:
- An entity or collection key, or an actual value.
- 抛出:
HibernateException- An error from HibernateSQLException- An error from the JDBC driver- 另请参阅:
Type.resolve(java.lang.Object, org.hibernate.engine.spi.SharedSessionContractImplementor, java.lang.Object)
-
resolve
public final Object resolve(Object value, SharedSessionContractImplementor session, Object owner) throws HibernateException
-
semiResolve
public final Object semiResolve(Object value, SharedSessionContractImplementor session, Object owner) throws HibernateException
从接口复制的说明:TypeGiven a hydrated, but unresolved value, return a value that may be used to reconstruct property-ref associations.- 指定者:
semiResolve在接口中Type- 参数:
value- The unresolved, hydrated valuesession- THe originating sessionowner- The value owner- 返回:
- The semi-resolved value
- 抛出:
HibernateException- An error from Hibernate
-
getSemiResolvedType
public final Type getSemiResolvedType(SessionFactoryImplementor factory)
从接口复制的说明:TypeAs part of 2-phase loading, when we perform resolving what is the resolved type for this type? Generally speaking the type and its semi-resolved type will be the same. The main deviation from this is in the case of an entity where the type would be the entity type and semi-resolved type would be its identifier type- 指定者:
getSemiResolvedType在接口中Type- 参数:
factory- The session factory- 返回:
- The semi-resolved type
-
replace
public final Object replace(Object original, Object target, SharedSessionContractImplementor session, Object owner, Map copyCache)
从接口复制的说明:TypeDuring merge, replace the existing (target) value in the entity we are merging to with a new (original) value from the detached entity we are merging. For immutable objects, or null values, it is safe to simply return the first parameter. For mutable objects, it is safe to return a copy of the first parameter. For objects with component values, it might make sense to recursively replace component values.
-
replace
public Object replace(Object original, Object target, SharedSessionContractImplementor session, Object owner, Map copyCache, ForeignKeyDirection foreignKeyDirection)
从接口复制的说明:TypeDuring merge, replace the existing (target) value in the entity we are merging to with a new (original) value from the detached entity we are merging. For immutable objects, or null values, it is safe to simply return the first parameter. For mutable objects, it is safe to return a copy of the first parameter. For objects with component values, it might make sense to recursively replace component values.- 指定者:
replace在接口中Type- 参数:
original- the value from the detached entity being mergedtarget- the value in the managed entitysession- The originating sessionowner- The owner of the valuecopyCache- The cache of already copied/replaced valuesforeignKeyDirection- For associations, which direction does the foreign key point?- 返回:
- the value to be merged
-
canDoExtraction
public boolean canDoExtraction()
从接口复制的说明:ProcedureParameterExtractionAwareCan the given instance of this type actually perform the parameter value extractions?- 指定者:
canDoExtraction在接口中ProcedureParameterExtractionAware<T>- 返回:
trueindicates that @{link #extract} calls will not fail due toIllegalStateException.
-
extract
public T extract(CallableStatement statement, int startIndex, SharedSessionContractImplementor session) throws SQLException
从接口复制的说明:ProcedureParameterExtractionAwarePerform the extraction- 指定者:
extract在接口中ProcedureParameterExtractionAware<T>- 参数:
statement- The CallableStatement from which to extract the parameter value(s).startIndex- The parameter index from which to start extracting; assumes the values (if multiple) are contiguoussession- The originating session- 返回:
- The extracted value.
- 抛出:
SQLException- Indicates an issue calling into the CallableStatement
-
extract
public T extract(CallableStatement statement, String[] paramNames, SharedSessionContractImplementor session) throws SQLException
从接口复制的说明:ProcedureParameterExtractionAwarePerform the extraction- 指定者:
extract在接口中ProcedureParameterExtractionAware<T>- 参数:
statement- The CallableStatement from which to extract the parameter value(s).paramNames- The parameter names.session- The originating session- 返回:
- The extracted value.
- 抛出:
SQLException- Indicates an issue calling into the CallableStatement
-
nullSafeSet
public void nullSafeSet(CallableStatement st, Object value, String name, SharedSessionContractImplementor session) throws SQLException
从接口复制的说明:ProcedureParameterNamedBinderBind a value to the JDBC prepared statement, ignoring some columns as dictated by the 'settable' parameter. Implementors should handle the possibility of null values. Does not support multi-column type- 指定者:
nullSafeSet在接口中ProcedureParameterNamedBinder- 参数:
st- The CallableStatement to which to bindvalue- the object to writename- parameter bind namesession- The originating session- 抛出:
SQLException- An error from the JDBC driver
-
nullSafeSet
protected final void nullSafeSet(CallableStatement st, Object value, String name, WrapperOptions options) throws SQLException
- 抛出:
SQLException
-
canDoSetting
public boolean canDoSetting()
从接口复制的说明:ProcedureParameterNamedBinderCan the given instance of this type actually set the parameter value by name- 指定者:
canDoSetting在接口中ProcedureParameterNamedBinder- 返回:
trueindicates that @{link #nullSafeSet} calls will not fail
-
-