public abstract class StompCommonClient extends ReactorClient
ReactorClient.MessageListener
Modifier and Type | Field and Description |
---|---|
protected CountDownLatch |
connected |
protected ByteBuffer |
headerBuffer |
protected Message |
message |
static String |
REQUEST_QUEUE |
static String |
RESPONSE_QUEUE |
protected CountDownLatch |
subscribed |
protected String |
subscribtionId |
BUFFER_SIZE, channel, CLIENT_CLOSED, eventListeners, ibuff, key, outbox, policy, reactor
Constructor and Description |
---|
StompCommonClient(Reactor reactor,
String hostname,
int port) |
Modifier and Type | Method and Description |
---|---|
protected byte[] |
buildNetworkResponse(String reason)
Builds network issue message for specific protocol.
|
Future<Void> |
close() |
protected void |
emitOnMessageReceived(Message message) |
protected void |
processIncoming()
Process incoming channel.
|
void |
send(byte[] message) |
addEventListener, connect, disconnect, emitOnMessageReceived, getClientId, getHostname, getPostConnectCallback, getRetryPolicy, getSelectionKey, isInInit, isOpen, postDisconnect, process, processOutgoing, read, removeEventListener, scheduleTask, sendMessage, setRetryPolicy, updateInterestedOps, updateLastHeartbeat
public static final String REQUEST_QUEUE
public static final String RESPONSE_QUEUE
protected ByteBuffer headerBuffer
protected Message message
protected CountDownLatch connected
protected CountDownLatch subscribed
protected String subscribtionId
public void send(byte[] message)
public Future<Void> close()
close
in class ReactorClient
protected void processIncoming() throws IOException, ClientConnectionException
ReactorClient
processIncoming
in class ReactorClient
IOException
- Thrown when reading issue occurred.ClientConnectionException
- Thrown when issues with connection.protected void emitOnMessageReceived(Message message)
protected byte[] buildNetworkResponse(String reason)
ReactorClient
buildNetworkResponse
in class ReactorClient
Copyright © 2015. All rights reserved.