|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Objectorg.seasar.kuina.dao.internal.condition.AbstractConditionalExpressionBuilder
org.seasar.kuina.dao.internal.condition.LikeBuilder
public class LikeBuilder
LIKEを使用した問い合わせ条件を作成し,SELECT文に追加するビルダです.
このビルダは,次のようなCriteria API呼び出しを行います.
statement.where(like("pathExpression", parameter("parameterName", vale)));
likeはoperationMethodで表されるメソッドです.
parameterはparameterMethodで表されるメソッドです.
| フィールドの概要 | |
|---|---|
protected String |
prefix
パターンのプレフィックス |
protected String |
suffix
パターンのサフィックス |
| クラス org.seasar.kuina.dao.internal.condition.AbstractConditionalExpressionBuilder から継承されたフィールド |
|---|
entityClass, operationMethod, parameterMethod, parameterName, pathExpression, propertyPath |
| コンストラクタの概要 | |
|---|---|
LikeBuilder(Class<?> entityClass,
String propertyPath,
String parameterName,
Method parameterMethod,
Method operationMethod,
String prefix,
String suffix)
インスタンスを構築します。 |
|
| メソッドの概要 | |
|---|---|
String |
appendCondition(SelectStatement statement,
Object value)
問い合わせ条件等を作成してSELECT文に追加します. |
| クラス org.seasar.kuina.dao.internal.condition.AbstractConditionalExpressionBuilder から継承されたメソッド |
|---|
getOperationMethod, getParameterMethod, getParameterName, getPathExpression, getPropertyPath, toPathExpression |
| クラス java.lang.Object から継承されたメソッド |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| フィールドの詳細 |
|---|
protected String prefix
protected String suffix
| コンストラクタの詳細 |
|---|
public LikeBuilder(Class<?> entityClass,
String propertyPath,
String parameterName,
Method parameterMethod,
Method operationMethod,
String prefix,
String suffix)
entityClass - エンティティ・クラスpropertyPath - プロパティのパスparameterName - パラメータ名parameterMethod - CriteriaOperationsのparameter()メソッドoperationMethod - CriteriaOperationsの問い合わせ条件作成メソッドprefix - パターンのプレフィックスsuffix - パターンのサフィックス| メソッドの詳細 |
|---|
public String appendCondition(SelectStatement statement,
Object value)
ConditionalExpressionBuilder の記述:
valueをパラメータにバインドした場合はパラメータ名を返します. パラメータをバインドしなかった場合はnullを返します.
多くのビルダ実装クラスではvalueがnullの場合はパラメータをバインドしません.
statement - SELECT文value - 問い合わせ条件にバインドするパラメータの値
valueをパラメータにバインドした場合はパラメータ名
|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||