public class MessageSocket extends C4Socket implements ReplicatorConnection
AUTH_TYPE_BASIC, AUTH_TYPE_CLIENT_CERT, AUTH_TYPE_FACEBOOK, AUTH_TYPE_OPEN_ID_CONNECT, AUTH_TYPE_SESSION, NO_FRAMING, REPLICATOR_AUTH_CLIENT_CERT, REPLICATOR_AUTH_PASSWORD, REPLICATOR_AUTH_TYPE, REPLICATOR_AUTH_USER_NAME, REPLICATOR_CHECKPOINT_INTERVAL, REPLICATOR_HEARTBEAT_INTERVAL, REPLICATOR_OPTION_AUTHENTICATION, REPLICATOR_OPTION_CHANNELS, REPLICATOR_OPTION_COOKIES, REPLICATOR_OPTION_DISABLE_DELTAS, REPLICATOR_OPTION_DOC_IDS, REPLICATOR_OPTION_EXTRA_HEADERS, REPLICATOR_OPTION_FILTER, REPLICATOR_OPTION_FILTER_PARAMS, REPLICATOR_OPTION_NO_CONFLICTS, REPLICATOR_OPTION_NO_INCOMING_CONFLICTS, REPLICATOR_OPTION_OUTGOING_CONFLICTS, REPLICATOR_OPTION_PINNED_SERVER_CERT, REPLICATOR_OPTION_PROGRESS_LEVEL, REPLICATOR_OPTION_REMOTE_DB_UNIQUE_ID, REPLICATOR_OPTION_SKIP_DELETED, REPLICATOR_RESET_CHECKPOINT, SOCKET_OPTION_HEARTBEAT, SOCKET_OPTION_WS_PROTOCOLS, WEB_SOCKET_CLIENT_FRAMING, WEB_SOCKET_SERVER_FRAMING, WEBSOCKET_SCHEME, WEBSOCKET_SECURE_CONNECTION_SCHEME
Constructor and Description |
---|
MessageSocket(long handle,
MessageEndpoint endpoint) |
MessageSocket(MessageEndpointConnection connection,
ProtocolType protocolType) |
Modifier and Type | Method and Description |
---|---|
void |
close(MessagingError error)
Tells the replicator to close the current replicator connection.
|
void |
receive(Message message)
Tells the replicator to consume the data received from the other peer.
|
public MessageSocket(long handle, MessageEndpoint endpoint)
public MessageSocket(MessageEndpointConnection connection, ProtocolType protocolType)
public void close(MessagingError error)
ReplicatorConnection
close
in interface ReplicatorConnection
error
- the error if anypublic void receive(@NonNull Message message)
ReplicatorConnection
receive
in interface ReplicatorConnection
message
- the message