Package com.couchbase.lite
Class URLEndpointListener
java.lang.Object
com.couchbase.lite.URLEndpointListener
ENTERPRISE EDITION API
A listener to which remote replicators can connect.
-
Constructor Summary
ConstructorDescriptionCreate a URLEndpointListener with the passed configuration. -
Method Summary
Modifier and TypeMethodDescriptionGet the listener's configuration.int
getPort()
Get the listener's port.Get the listener status.Get the TLS identity used by the listener.getUrls()
Get the list of URIs for the listener.void
start()
Start the listener.void
stop()
Stop the listener.toString()
-
Constructor Details
-
URLEndpointListener
Create a URLEndpointListener with the passed configuration.- Parameters:
config
- the listener configuration.
-
-
Method Details
-
getConfig
Get the listener's configuration.- Returns:
- the listener's configuration (read only).
-
getPort
public int getPort()Get the listener's port. This method will return a value of -1 except between the time the listener is started and the time it is stopped.When a listener is configured with the port number 0, the return value from this function will give the port at which the listener is actually listening.
- Returns:
- the listener's port, or -1.
-
getUrls
Get the list of URIs for the listener.- Returns:
- a list of listener URIs.
-
getStatus
Get the listener status.- Returns:
- listener status.
-
getTlsIdentity
Get the TLS identity used by the listener.- Returns:
- TLS identity.
-
start
Start the listener.- Throws:
CouchbaseLiteException
-
stop
public void stop()Stop the listener. -
toString
-