public class QuerydslBindings extends ObjectSE
QuerydslBindings では、パス固有のバインディングを定義できます。
new QuerydslBindings() {
{
bind(QUser.user.address.city).first((path, value) -> path.like(value.toString()));
bind(String.class).first((path, value) -> path.like(value.toString()));
}
}
バインディングは、単一(QuerydslBindings.PathBinder.first(SingleValueBinding) を参照)または複数(複数のバインディングが提供されている場合は最初)または複数(QuerydslBindings.PathBinder.all(MultiValueBinding) を参照)の値バインディングを処理できます。正確に 1 つのパスがデプロイされている場合、QuerydslBindings.AliasingPathBinder が返されます。これは、名前が示すように、パスのエイリアシングを許可します。つまり、別の名前でパスを公開します。QuerydslBindings は通常、QuerydslBinderCustomizer を使用して操作され、直接実装されるか、Spring Data リポジトリのデフォルトメソッドを使用します。
QuerydslBinderCustomizer| 修飾子と型 | クラスと説明 |
|---|---|
class | QuerydslBindings.AliasingPathBinder<P extends com.querydsl.core.types.Path<? extends T>,T> 専用エイリアスでバインディングを追加登録する特別な QuerydslBindings.PathBinder。 |
class | QuerydslBindings.PathBinder<P extends com.querydsl.core.types.Path<? extends T>,T>Path 用のバインダー。 |
class | QuerydslBindings.TypeBinder<T> 型のバインダー。 |
| コンストラクターと説明 |
|---|
QuerydslBindings() 新しい QuerydslBindings インスタンスを作成します。 |
| 修飾子と型 | メソッドと説明 |
|---|---|
<T> QuerydslBindings.TypeBinder<T> | bind(ClassSE<T> type) 指定された型の新しい QuerydslBindings.TypeBinder を返します。 |
<T extends com.querydsl.core.types.Path<S>,S> | bind(T... paths) 指定された Path の新しい QuerydslBindings.PathBinder を返し、それらのバインディングを定義します。 |
<T extends com.querydsl.core.types.Path<S>,S> | bind(T path) 指定された Path の QuerydslBindings.AliasingPathBinder を返し、それらのバインディングを定義します。 |
QuerydslBindings | excludeUnlistedProperties(boolean excludeUnlistedProperties) 明示的なバインディングが定義されていない、または明示的にホワイトリストに登録されているすべてのプロパティを除外するかどうかを返します。 |
void | excluding(com.querydsl.core.types.Path<?>... paths) プロパティをバインディングから除外します。 |
<S extends com.querydsl.core.types.Path<? extends T>,T> | getBindingForPath(org.springframework.data.querydsl.binding.PathInformation path) 指定された PropertyPath の SingleValueBinding を返します。 |
void | including(com.querydsl.core.types.Path<?>... paths) バインディングのプロパティを含めます。 |
cloneSE, equalsSE, finalizeSE, getClassSE, hashCodeSE, notifySE, notifyAllSE, toStringSE, waitSE, waitSE, waitSEpublic QuerydslBindings()
QuerydslBindings インスタンスを作成します。public final <T extends com.querydsl.core.types.Path<S>,S> QuerydslBindings.AliasingPathBinder<T,S> bind(T path)
Path の QuerydslBindings.AliasingPathBinder を返し、それらのバインディングを定義します。path - null であってはなりません。@SafeVarargsSE public final <T extends com.querydsl.core.types.Path<S>,S> QuerydslBindings.PathBinder<T,S> bind(T... paths)
Path の新しい QuerydslBindings.PathBinder を返し、それらのバインディングを定義します。paths - null または空であってはなりません。public final <T> QuerydslBindings.TypeBinder<T> bind(ClassSE<T> type)
QuerydslBindings.TypeBinder を返します。type - null であってはなりません。public final void excluding(com.querydsl.core.types.Path<?>... paths)
address は、address.city と address.street の両方を除外します。paths - null または空であってはなりません。public final void including(com.querydsl.core.types.Path<?>... paths)
properties - null または空であってはなりません。public final QuerydslBindings excludeUnlistedProperties(boolean excludeUnlistedProperties)
excludeUnlistedProperties -#including(String...), including(Path...)public <S extends com.querydsl.core.types.Path<? extends T>,T> OptionalSE<MultiValueBinding<S,T>> getBindingForPath(org.springframework.data.querydsl.binding.PathInformation path)
PropertyPath の SingleValueBinding を返します。特定のパス用に構成されたパスを優先しますが、特定の型用に登録されたビルダーにフォールバックします。path - null であってはなりません。Copyright © 2011–2020 Pivotal Software, Inc.. All rights reserved.