Package com.couchbase.lite
Class MultipeerCollectionConfiguration
java.lang.Object
com.couchbase.lite.MultipeerCollectionConfiguration
A configuration for a collection in a multipeer environment.
This class allows you to configure document IDs to filter, push and pull filters, and a custom conflict resolver for an associated collection.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
The builder for MultipeerCollectionConfigurations.static interface
The conflict resolver interface.static interface
The replication filter interface. -
Method Summary
Modifier and TypeMethodDescriptionstatic Set<MultipeerCollectionConfiguration>
fromCollections
(Collection<Collection> collections) Creates a set ofMultipeerCollectionConfiguration
instances from the given collections.The collection.Custom conflict resolver (possibly null).Document IDs filter (possibly null).Pull filter (possibly null).Push filter (possibly null).
-
Method Details
-
fromCollections
@NonNull public static Set<MultipeerCollectionConfiguration> fromCollections(@NonNull Collection<Collection> collections) Creates a set ofMultipeerCollectionConfiguration
instances from the given collections.Each specified collection will be wrapped in a
MultipeerCollectionConfiguration
using default settings (no filters and no custom conflict resolvers).This is a convenience method for configuring multiple collections with default replication settings. If custom configurations are needed, construct
MultipeerCollectionConfiguration
instances directly instead.- Parameters:
collections
- A collection ofCollection
instances to replicate.- Returns:
- A set of
MultipeerCollectionConfiguration
instances for the provided collections.
-
getCollection
The collection. -
getDocumentIDs
Document IDs filter (possibly null). -
getPushFilter
Push filter (possibly null). -
getPullFilter
Pull filter (possibly null). -
getConflictResolver
Custom conflict resolver (possibly null).
-