public interface ICloverTransport
Modifier and Type | Method and Description |
---|---|
void |
addObserver(ICloverTransportObserver observer)
Registers a listener to receive connect events and messages from the transport
|
void |
dispose()
Closes the connection to the underlying transport
|
void |
initializeConnection()
Initializes the connection using the underlying transport
|
void |
removeObserver(ICloverTransportObserver observer)
Remove a previously added listener.
|
int |
sendMessage(java.lang.String message)
Sends the specified encoded message
|
void initializeConnection()
void dispose()
void addObserver(ICloverTransportObserver observer)
observer
- listener to addvoid removeObserver(ICloverTransportObserver observer)
observer
- listener to removeint sendMessage(java.lang.String message) throws java.nio.channels.NotYetConnectedException
message
- encoded message to sendjava.nio.channels.NotYetConnectedException
- if the message is sent when the underlying transport is not connected