public class ReactiveRepositoryOperationsMapping extends Object
| Constructor and Description |
|---|
ReactiveRepositoryOperationsMapping(RxJavaCouchbaseOperations defaultOperations)
Creates a new mapping, setting the default fallback to use by otherwise non mapped repositories.
|
| Modifier and Type | Method and Description |
|---|---|
RxJavaCouchbaseOperations |
getDefault() |
MappingContext<? extends CouchbasePersistentEntity<?>,CouchbasePersistentProperty> |
getMappingContext()
Get the
MappingContext to use in repositories. |
ReactiveRepositoryOperationsMapping |
map(Class<?> repositoryInterface,
RxJavaCouchbaseOperations operations)
Add a highest priority mapping that will associate a specific repository interface with a given
RxJavaCouchbaseOperations. |
ReactiveRepositoryOperationsMapping |
mapEntity(Class<?> entityClass,
RxJavaCouchbaseOperations operations)
Add a middle priority mapping that will associate any un-mapped repository that deals with the given domain type
Class with a given
CouchbaseOperations. |
RxJavaCouchbaseOperations |
resolve(Class<?> repositoryInterface,
Class<?> domainType)
Given a repository interface and its domain type, resolves which
RxJavaCouchbaseOperations it should be backed with. |
ReactiveRepositoryOperationsMapping |
setDefault(RxJavaCouchbaseOperations aDefault)
Change the default reactive couchbase operations in an existing mapping.
|
public ReactiveRepositoryOperationsMapping(RxJavaCouchbaseOperations defaultOperations)
defaultOperations - the default fallback reactive couchbase operations.public ReactiveRepositoryOperationsMapping setDefault(RxJavaCouchbaseOperations aDefault)
aDefault - the new default couchbase operations.public ReactiveRepositoryOperationsMapping map(Class<?> repositoryInterface, RxJavaCouchbaseOperations operations)
RxJavaCouchbaseOperations.repositoryInterface - the repository interface Class.operations - the ReactiveCouchbaseOperations to use.public ReactiveRepositoryOperationsMapping mapEntity(Class<?> entityClass, RxJavaCouchbaseOperations operations)
CouchbaseOperations.entityClass - the domain type's Class.operations - the CouchbaseOperations to use.public RxJavaCouchbaseOperations getDefault()
RxJavaCouchbaseOperations.public MappingContext<? extends CouchbasePersistentEntity<?>,CouchbasePersistentProperty> getMappingContext()
MappingContext to use in repositories. It is extracted from the default RxJavaCouchbaseOperations.public RxJavaCouchbaseOperations resolve(Class<?> repositoryInterface, Class<?> domainType)
RxJavaCouchbaseOperations it should be backed with.
Starts by looking for a direct mapping to the interface, then a common mapping for the domain type, then falls back
to the default CouchbaseOperations.repositoryInterface - the repository's interface.domainType - the repository's domain type / entity.Copyright © 2011–2018 Pivotal Software, Inc.. All rights reserved.