CBLURLEndpointListener


@interface CBLURLEndpointListener : NSObject

ENTERPRISE EDITION ONLY.

A listener to provide websocket based endpoint for peer-to-peer replication. Once the listener is started, peer replicators can connect to the listener by using CBLURLEndpoint.

  • The read-only configuration.

    Declaration

    Objective-C

    @property (nonatomic, readonly) CBLURLEndpointListenerConfiguration *_Nonnull config;
  • The port that the listener is listening to. If the listener is not started, the port property will be zero.

    Declaration

    Objective-C

    @property (nonatomic, readonly) unsigned short port;
  • The TLS identity used by the listener to provide TLS communication. If the listener is not started or the TLS is disabled, the property value will be nil.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nullable) CBLTLSIdentity *tlsIdentity;
  • The possible URLs of the listener. If the listener is not started, the urls property will be nil.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nullable) NSArray<NSURL *> *urls;
  • The current connection status of the listener.

    Declaration

    Objective-C

    @property (nonatomic, readonly) CBLConnectionStatus status;
  • Initializes a listener with the given configuration object.

    Declaration

    Objective-C

    - (nonnull instancetype)initWithConfig:
        (nonnull CBLURLEndpointListenerConfiguration *)config;
  • Starts the listener.

    Declaration

    Objective-C

    - (BOOL)startWithError:(NSError *_Nullable *_Nullable)error;
  • Stop the listener.

    Declaration

    Objective-C

    - (void)stop;
  • Undocumented

    Declaration

    Objective-C

    - (instancetype) init NS_UNAVAILABLE;