public class OptionsBuilder extends Object
| Constructor and Description |
|---|
OptionsBuilder() |
| Modifier and Type | Method and Description |
|---|---|
static <A extends Annotation,V> |
annotation(Class<A> annotation,
String attributeName,
V defaultValue,
AnnotatedElement... elements)
return the first merged annotation which does not have attribute with null/defaultValue from the listed elements.
|
static <A extends Annotation,V> |
annotation(Class<A> annotation,
V defaultValue,
AnnotatedElement[] elements) |
static <A extends Annotation,V> |
annotationAttribute(Class<A> annotation,
String attributeName,
V defaultValue,
AnnotatedElement[] elements)
return the first merged annotation which is not null/defaultValue from the listed elements.
|
static <A extends Annotation> |
annotationString(Class<A> annotation,
Object defaultValue,
AnnotatedElement[] elements) |
static <A extends Annotation> |
annotationString(Class<A> annotation,
String attributeName,
Object defaultValue,
AnnotatedElement[] elements)
return the toString() of the first merged annotation which is not null/defaultValue from the listed elements.
|
static com.couchbase.client.java.kv.ExistsOptions |
buildExistsOptions(com.couchbase.client.java.kv.ExistsOptions options) |
static com.couchbase.client.java.kv.InsertOptions |
buildInsertOptions(com.couchbase.client.java.kv.InsertOptions options,
com.couchbase.client.java.kv.PersistTo persistTo,
com.couchbase.client.java.kv.ReplicateTo replicateTo,
com.couchbase.client.core.msg.kv.DurabilityLevel durabilityLevel,
Duration expiry,
CouchbaseDocument doc) |
static Meta |
buildMeta(CouchbaseQueryMethod method,
Class<?> typeToRead) |
static com.couchbase.client.java.kv.RemoveOptions |
buildRemoveOptions(com.couchbase.client.java.kv.RemoveOptions options,
com.couchbase.client.java.kv.PersistTo persistTo,
com.couchbase.client.java.kv.ReplicateTo replicateTo,
com.couchbase.client.core.msg.kv.DurabilityLevel durabilityLevel,
Long cas) |
static com.couchbase.client.java.kv.ReplaceOptions |
buildReplaceOptions(com.couchbase.client.java.kv.ReplaceOptions options,
com.couchbase.client.java.kv.PersistTo persistTo,
com.couchbase.client.java.kv.ReplicateTo replicateTo,
com.couchbase.client.core.msg.kv.DurabilityLevel durabilityLevel,
Duration expiry,
Long cas,
CouchbaseDocument doc) |
static com.couchbase.client.java.kv.UpsertOptions |
buildUpsertOptions(com.couchbase.client.java.kv.UpsertOptions options,
com.couchbase.client.java.kv.PersistTo persistTo,
com.couchbase.client.java.kv.ReplicateTo replicateTo,
com.couchbase.client.core.msg.kv.DurabilityLevel durabilityLevel,
Duration expiry,
CouchbaseDocument doc) |
static <T> T |
fromFirst(T deflt,
Object... choice)
Get the most-specific
|
static String |
getCollectionFrom(Class<?> domainType) |
static String |
getScopeFrom(Class<?> domainType)
scope annotation could be a
|
public static com.couchbase.client.java.kv.ExistsOptions buildExistsOptions(com.couchbase.client.java.kv.ExistsOptions options)
public static com.couchbase.client.java.kv.InsertOptions buildInsertOptions(com.couchbase.client.java.kv.InsertOptions options,
com.couchbase.client.java.kv.PersistTo persistTo,
com.couchbase.client.java.kv.ReplicateTo replicateTo,
com.couchbase.client.core.msg.kv.DurabilityLevel durabilityLevel,
Duration expiry,
CouchbaseDocument doc)
public static com.couchbase.client.java.kv.UpsertOptions buildUpsertOptions(com.couchbase.client.java.kv.UpsertOptions options,
com.couchbase.client.java.kv.PersistTo persistTo,
com.couchbase.client.java.kv.ReplicateTo replicateTo,
com.couchbase.client.core.msg.kv.DurabilityLevel durabilityLevel,
Duration expiry,
CouchbaseDocument doc)
public static com.couchbase.client.java.kv.ReplaceOptions buildReplaceOptions(com.couchbase.client.java.kv.ReplaceOptions options,
com.couchbase.client.java.kv.PersistTo persistTo,
com.couchbase.client.java.kv.ReplicateTo replicateTo,
com.couchbase.client.core.msg.kv.DurabilityLevel durabilityLevel,
Duration expiry,
Long cas,
CouchbaseDocument doc)
public static com.couchbase.client.java.kv.RemoveOptions buildRemoveOptions(com.couchbase.client.java.kv.RemoveOptions options,
com.couchbase.client.java.kv.PersistTo persistTo,
com.couchbase.client.java.kv.ReplicateTo replicateTo,
com.couchbase.client.core.msg.kv.DurabilityLevel durabilityLevel,
Long cas)
public static String getScopeFrom(Class<?> domainType)
domainType - public static <T> T fromFirst(T deflt,
Object... choice)
T - deflt - the default value, which we treat as not setchoice - array of values or Optional<values>, ordered from most to least specificpublic static Meta buildMeta(CouchbaseQueryMethod method, Class<?> typeToRead)
public static <A extends Annotation,V> A annotation(Class<A> annotation, String attributeName, V defaultValue, AnnotatedElement... elements)
A - annotation - attributeName - defaultValue - elements - public static <A extends Annotation,V> A annotation(Class<A> annotation, V defaultValue, AnnotatedElement[] elements)
public static <A extends Annotation,V> V annotationAttribute(Class<A> annotation, String attributeName, V defaultValue, AnnotatedElement[] elements)
A - annotation - defaultValue - elements - public static <A extends Annotation> String annotationString(Class<A> annotation, String attributeName, Object defaultValue, AnnotatedElement[] elements)
A - annotation - defaultValue - elements - public static <A extends Annotation> String annotationString(Class<A> annotation, Object defaultValue, AnnotatedElement[] elements)
Copyright © 2011–2022 Pivotal Software, Inc.. All rights reserved.