public class ReactiveCouchbaseTemplate extends Object implements ReactiveCouchbaseOperations, ApplicationContextAware
ReactiveUpsertByIdOperation.ReactiveUpsertById<T>, ReactiveUpsertByIdOperation.TerminatingUpsertById<T>, ReactiveUpsertByIdOperation.UpsertByIdInCollection<T>, ReactiveUpsertByIdOperation.UpsertByIdInScope<T>, ReactiveUpsertByIdOperation.UpsertByIdWithDurability<T>, ReactiveUpsertByIdOperation.UpsertByIdWithExpiry<T>, ReactiveUpsertByIdOperation.UpsertByIdWithOptions<T>ReactiveInsertByIdOperation.InsertByIdInCollection<T>, ReactiveInsertByIdOperation.InsertByIdInScope<T>, ReactiveInsertByIdOperation.InsertByIdWithDurability<T>, ReactiveInsertByIdOperation.InsertByIdWithExpiry<T>, ReactiveInsertByIdOperation.InsertByIdWithOptions<T>, ReactiveInsertByIdOperation.ReactiveInsertById<T>, ReactiveInsertByIdOperation.TerminatingInsertById<T>ReactiveReplaceByIdOperation.ReactiveReplaceById<T>, ReactiveReplaceByIdOperation.ReplaceByIdInCollection<T>, ReactiveReplaceByIdOperation.ReplaceByIdInScope<T>, ReactiveReplaceByIdOperation.ReplaceByIdWithDurability<T>, ReactiveReplaceByIdOperation.ReplaceByIdWithExpiry<T>, ReactiveReplaceByIdOperation.ReplaceByIdWithOptions<T>, ReactiveReplaceByIdOperation.TerminatingReplaceById<T>ReactiveFindByIdOperation.FindByIdInCollection<T>, ReactiveFindByIdOperation.FindByIdInScope<T>, ReactiveFindByIdOperation.FindByIdWithExpiry<T>, ReactiveFindByIdOperation.FindByIdWithOptions<T>, ReactiveFindByIdOperation.FindByIdWithProjection<T>, ReactiveFindByIdOperation.ReactiveFindById<T>, ReactiveFindByIdOperation.TerminatingFindById<T>ReactiveExistsByIdOperation.ExistsByIdInCollection, ReactiveExistsByIdOperation.ExistsByIdInScope, ReactiveExistsByIdOperation.ExistsByIdWithOptions, ReactiveExistsByIdOperation.ReactiveExistsById, ReactiveExistsByIdOperation.TerminatingExistsByIdReactiveFindByAnalyticsOperation.FindByAnalyticsConsistentWith<T>, ReactiveFindByAnalyticsOperation.FindByAnalyticsInCollection<T>, ReactiveFindByAnalyticsOperation.FindByAnalyticsInScope<T>, ReactiveFindByAnalyticsOperation.FindByAnalyticsWithConsistency<T>, ReactiveFindByAnalyticsOperation.FindByAnalyticsWithOptions<T>, ReactiveFindByAnalyticsOperation.FindByAnalyticsWithProjection<T>, ReactiveFindByAnalyticsOperation.FindByAnalyticsWithQuery<T>, ReactiveFindByAnalyticsOperation.ReactiveFindByAnalytics<T>, ReactiveFindByAnalyticsOperation.TerminatingFindByAnalytics<T>ReactiveFindFromReplicasByIdOperation.FindFromReplicasByIdInCollection<T>, ReactiveFindFromReplicasByIdOperation.FindFromReplicasByIdInScope<T>, ReactiveFindFromReplicasByIdOperation.FindFromReplicasByIdWithOptions<T>, ReactiveFindFromReplicasByIdOperation.ReactiveFindFromReplicasById<T>, ReactiveFindFromReplicasByIdOperation.TerminatingFindFromReplicasById<T>ReactiveFindByQueryOperation.FindByQueryConsistentWith<T>, ReactiveFindByQueryOperation.FindByQueryInCollection<T>, ReactiveFindByQueryOperation.FindByQueryInScope<T>, ReactiveFindByQueryOperation.FindByQueryWithConsistency<T>, ReactiveFindByQueryOperation.FindByQueryWithDistinct<T>, ReactiveFindByQueryOperation.FindByQueryWithOptions<T>, ReactiveFindByQueryOperation.FindByQueryWithProjecting<T>, ReactiveFindByQueryOperation.FindByQueryWithProjection<T>, ReactiveFindByQueryOperation.FindByQueryWithQuery<T>, ReactiveFindByQueryOperation.ReactiveFindByQuery<T>, ReactiveFindByQueryOperation.TerminatingFindByQuery<T>ReactiveRemoveByIdOperation.ReactiveRemoveById, ReactiveRemoveByIdOperation.RemoveByIdInCollection, ReactiveRemoveByIdOperation.RemoveByIdInScope, ReactiveRemoveByIdOperation.RemoveByIdWithCas, ReactiveRemoveByIdOperation.RemoveByIdWithDurability, ReactiveRemoveByIdOperation.RemoveByIdWithOptions, ReactiveRemoveByIdOperation.TerminatingRemoveByIdReactiveRemoveByQueryOperation.ReactiveRemoveByQuery<T>, ReactiveRemoveByQueryOperation.RemoveByQueryConsistentWith<T>, ReactiveRemoveByQueryOperation.RemoveByQueryInCollection<T>, ReactiveRemoveByQueryOperation.RemoveByQueryInScope<T>, ReactiveRemoveByQueryOperation.RemoveByQueryWithConsistency<T>, ReactiveRemoveByQueryOperation.RemoveByQueryWithOptions<T>, ReactiveRemoveByQueryOperation.RemoveByQueryWithQuery<T>, ReactiveRemoveByQueryOperation.TerminatingRemoveByQuery<T>| Constructor and Description |
|---|
ReactiveCouchbaseTemplate(CouchbaseClientFactory clientFactory,
CouchbaseConverter converter) |
ReactiveCouchbaseTemplate(CouchbaseClientFactory clientFactory,
CouchbaseConverter converter,
TranslationService translationService) |
ReactiveCouchbaseTemplate(CouchbaseClientFactory clientFactory,
CouchbaseConverter converter,
TranslationService translationService,
com.couchbase.client.java.query.QueryScanConsistency scanConsistency) |
| Modifier and Type | Method and Description |
|---|---|
ReactiveExistsByIdOperation.ReactiveExistsById |
existsById()
Checks if the document exists in the bucket.
|
ReactiveExistsByIdOperation.ReactiveExistsById |
existsById(Class<?> domainType)
Checks if the document exists in the bucket.
|
<T> ReactiveFindByAnalyticsOperation.ReactiveFindByAnalytics<T> |
findByAnalytics(Class<T> domainType)
Queries the analytics service.
|
<T> ReactiveFindByIdOperation.ReactiveFindById<T> |
findById(Class<T> domainType)
Loads a document from a bucket.
|
<T> ReactiveFindByQueryOperation.ReactiveFindByQuery<T> |
findByQuery(Class<T> domainType)
Create the operation for the domainType
|
<T> ReactiveFindFromReplicasByIdOperation.ReactiveFindFromReplicasById<T> |
findFromReplicasById(Class<T> domainType)
Loads a document from a replica.
|
String |
getBucketName()
The name of the bucket used.
|
com.couchbase.client.java.Collection |
getCollection(String collectionName)
Provides access to a
Collection on the configured CouchbaseClientFactory. |
com.couchbase.client.java.query.QueryScanConsistency |
getConsistency() |
CouchbaseConverter |
getConverter()
Returns the converter used for this template/operations.
|
CouchbaseClientFactory |
getCouchbaseClientFactory()
Returns the underlying client factory.
|
PseudoArgs<?> |
getPseudoArgs() |
String |
getScopeName()
The name of the scope used, null if the default scope is used.
|
<T> ReactiveInsertByIdOperation.ReactiveInsertById<T> |
insertById(Class<T> domainType)
Insert using the KV service.
|
protected RuntimeException |
potentiallyConvertRuntimeException(RuntimeException ex)
Tries to convert the given
RuntimeException into a DataAccessException but returns the original
exception if the conversation failed. |
ReactiveRemoveByIdOperation.ReactiveRemoveById |
removeById()
Removes a document.
|
ReactiveRemoveByIdOperation.ReactiveRemoveById |
removeById(Class<?> domainType)
Removes a document.
|
<T> ReactiveRemoveByQueryOperation.ReactiveRemoveByQuery<T> |
removeByQuery(Class<T> domainType)
Remove via the query service.
|
<T> ReactiveReplaceByIdOperation.ReactiveReplaceById<T> |
replaceById(Class<T> domainType)
Replace using the KV service.
|
void |
setApplicationContext(ApplicationContext applicationContext) |
void |
setPseudoArgs(PseudoArgs<?> threadLocalArgs)
set the ThreadLocal field
|
ReactiveTemplateSupport |
support() |
<T> ReactiveUpsertByIdOperation.ReactiveUpsertById<T> |
upsertById(Class<T> domainType)
Upsert using the KV service.
|
public ReactiveCouchbaseTemplate(CouchbaseClientFactory clientFactory, CouchbaseConverter converter)
public ReactiveCouchbaseTemplate(CouchbaseClientFactory clientFactory, CouchbaseConverter converter, TranslationService translationService)
public ReactiveCouchbaseTemplate(CouchbaseClientFactory clientFactory, CouchbaseConverter converter, TranslationService translationService, com.couchbase.client.java.query.QueryScanConsistency scanConsistency)
public <T> ReactiveFindByIdOperation.ReactiveFindById<T> findById(Class<T> domainType)
ReactiveFindByIdOperationfindById in interface ReactiveFindByIdOperationdomainType - the entity type to use for the results.public ReactiveExistsByIdOperation.ReactiveExistsById existsById()
ReactiveExistsByIdOperationexistsById in interface ReactiveExistsByIdOperationpublic ReactiveExistsByIdOperation.ReactiveExistsById existsById(Class<?> domainType)
ReactiveExistsByIdOperationexistsById in interface ReactiveExistsByIdOperationpublic <T> ReactiveFindByAnalyticsOperation.ReactiveFindByAnalytics<T> findByAnalytics(Class<T> domainType)
ReactiveFindByAnalyticsOperationfindByAnalytics in interface ReactiveFindByAnalyticsOperationdomainType - the entity type to use for the results.public <T> ReactiveFindByQueryOperation.ReactiveFindByQuery<T> findByQuery(Class<T> domainType)
ReactiveFindByQueryOperationfindByQuery in interface ReactiveFindByQueryOperationdomainType - the entity type to use for the results.public <T> ReactiveFindFromReplicasByIdOperation.ReactiveFindFromReplicasById<T> findFromReplicasById(Class<T> domainType)
ReactiveFindFromReplicasByIdOperationfindFromReplicasById in interface ReactiveFindFromReplicasByIdOperationdomainType - the entity type to use for the results.public <T> ReactiveInsertByIdOperation.ReactiveInsertById<T> insertById(Class<T> domainType)
ReactiveInsertByIdOperationinsertById in interface ReactiveInsertByIdOperationdomainType - the entity type to insert.public ReactiveRemoveByIdOperation.ReactiveRemoveById removeById()
ReactiveRemoveByIdOperationremoveById in interface ReactiveRemoveByIdOperationpublic ReactiveRemoveByIdOperation.ReactiveRemoveById removeById(Class<?> domainType)
ReactiveRemoveByIdOperationremoveById in interface ReactiveRemoveByIdOperationpublic <T> ReactiveRemoveByQueryOperation.ReactiveRemoveByQuery<T> removeByQuery(Class<T> domainType)
ReactiveRemoveByQueryOperationremoveByQuery in interface ReactiveRemoveByQueryOperationpublic <T> ReactiveReplaceByIdOperation.ReactiveReplaceById<T> replaceById(Class<T> domainType)
ReactiveReplaceByIdOperationreplaceById in interface ReactiveReplaceByIdOperationdomainType - the entity type to replace.public <T> ReactiveUpsertByIdOperation.ReactiveUpsertById<T> upsertById(Class<T> domainType)
ReactiveUpsertByIdOperationupsertById in interface ReactiveUpsertByIdOperationdomainType - the entity type to upsert.public String getBucketName()
ReactiveCouchbaseOperationsgetBucketName in interface ReactiveCouchbaseOperationspublic String getScopeName()
ReactiveCouchbaseOperationsgetScopeName in interface ReactiveCouchbaseOperationspublic CouchbaseClientFactory getCouchbaseClientFactory()
ReactiveCouchbaseOperationsgetCouchbaseClientFactory in interface ReactiveCouchbaseOperationspublic com.couchbase.client.java.Collection getCollection(String collectionName)
Collection on the configured CouchbaseClientFactory.collectionName - the name of the collection, if null is passed in the default collection is assumed.public CouchbaseConverter getConverter()
ReactiveCouchbaseOperationsgetConverter in interface ReactiveCouchbaseOperationspublic ReactiveTemplateSupport support()
protected RuntimeException potentiallyConvertRuntimeException(RuntimeException ex)
RuntimeException into a DataAccessException but returns the original
exception if the conversation failed. Thus allows safe re-throwing of the return value.ex - the exception to translatepublic void setApplicationContext(ApplicationContext applicationContext) throws BeansException
setApplicationContext in interface ApplicationContextAwareBeansExceptionpublic PseudoArgs<?> getPseudoArgs()
public void setPseudoArgs(PseudoArgs<?> threadLocalArgs)
public com.couchbase.client.java.query.QueryScanConsistency getConsistency()
getConsistency in interface ReactiveCouchbaseOperationsCopyright © 2011–2022 Pivotal Software, Inc.. All rights reserved.