Replicator
public final class ReplicatorA replicator for replicating document changes between a local database and a target database. The replicator can be bidirectional or either push or pull. The replicator can also be one-short or continuous. The replicator runs asynchronously, so observe the status property to be notified of progress.
- 
                  
                  Activity level of a replicator. - stopped: The replicator is finished or hit a fatal error.
- offline: The replicator is offline as the remote host is unreachable.
- connecting: The replicator is connecting to the remote host.
- idle: The replicator is inactive waiting for changes or offline.
- busy: The replicator is actively transferring data.
 DeclarationSwift public enum ActivityLevel : UInt8
- 
                  
                  Progress of a replicator. If See moretotalis zero, the progress is indeterminate; otherwise, dividing the two will produce a fraction that can be used to draw a progress bar.DeclarationSwift public struct Progress
- 
                  
                  Combined activity level and progress of a replicator. See moreDeclarationSwift public struct Status
- 
                  
                  Initializes a replicator with the given configuration. DeclarationSwift public init(config: ReplicatorConfiguration)ParametersconfigThe configuration. 
- 
                  
                  The replicator’s configuration. DeclarationSwift public var config: ReplicatorConfiguration
- 
                  
                  The replicator’s current status: its activity level and progress. Observable. DeclarationSwift public var status: Status
- 
                  
                  Starts the replicator. This method returns immediately; the replicator runs asynchronously and will report its progress throuh the replicator change notification. DeclarationSwift public func start()
- 
                  
                  Stops a running replicator. This method returns immediately; when the replicator actually stops, the replicator will change its status’s activity level to .stoppedand the replicator change notification will be notified accordingly.DeclarationSwift public func stop()
- 
                  
                  Adds a replicator change listener. Changes will be posted on the main queue. DeclarationSwift @discardableResult public func addChangeListener( _ listener: @escaping (ReplicatorChange) -> Void) -> ListenerTokenParameterslistenerThe listener to post changes. Return ValueAn opaque listener token object for removing the listener. 
- 
                  
                  Adds a replicator change listener with the dispatch queue on which changes will be posted. If the dispatch queue is not specified, the changes will be posted on the main queue. DeclarationSwift @discardableResult public func addChangeListener(withQueue queue: DispatchQueue?, _ listener: @escaping (ReplicatorChange) -> Void) -> ListenerTokenParametersqueueThe dispatch queue. listenerThe listener to post changes. Return ValueAn opaque listener token object for removing the listener. 
- 
                  
                  Removes a change listener with the given listener token. DeclarationSwift public func removeChangeListener(withToken token: ListenerToken)ParameterstokenThe listener token. 
 Replicator Class Reference
        Replicator Class Reference