类 NaturalIdentifier
- java.lang.Object
-
- org.hibernate.criterion.NaturalIdentifier
-
- 所有已实现的接口:
Serializable,Criterion
public class NaturalIdentifier extends Object implements Criterion
An expression pertaining to an entity's defined natural identifier
-
-
构造器概要
构造器 构造器 说明 NaturalIdentifier()
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 Map<String,Object>getNaturalIdValues()Get a map of set of the natural identifier values set on this criterion (for composite natural identifiers this need not be the full set of properties).TypedValue[]getTypedValues(Criteria criteria, CriteriaQuery criteriaQuery)Return typed values for all parameters in the rendered SQL fragmentNaturalIdentifierset(String property, Object value)Set a natural identifier value for this expressionStringtoSqlString(Criteria criteria, CriteriaQuery criteriaQuery)Render the SQL fragment
-
-
-
方法详细资料
-
getTypedValues
public TypedValue[] getTypedValues(Criteria criteria, CriteriaQuery criteriaQuery) throws HibernateException
从接口复制的说明:CriterionReturn typed values for all parameters in the rendered SQL fragment- 指定者:
getTypedValues在接口中Criterion- 参数:
criteria- The local criteriacriteriaQuery- The overall criteria query- 返回:
- The types values (for binding)
- 抛出:
HibernateException- Problem determining types.
-
toSqlString
public String toSqlString(Criteria criteria, CriteriaQuery criteriaQuery) throws HibernateException
从接口复制的说明:CriterionRender the SQL fragment- 指定者:
toSqlString在接口中Criterion- 参数:
criteria- The local criteriacriteriaQuery- The overall criteria query- 返回:
- The generated SQL fragment
- 抛出:
HibernateException- Problem during rendering.
-
getNaturalIdValues
public Map<String,Object> getNaturalIdValues()
Get a map of set of the natural identifier values set on this criterion (for composite natural identifiers this need not be the full set of properties).- 返回:
- The value map.
-
set
public NaturalIdentifier set(String property, Object value)
Set a natural identifier value for this expression- 参数:
property- The specific property namevalue- The value to use- 返回:
this, for method chaining
-
-