Class AWebsocketConnection
- java.lang.Object
- 
- jadex.platform.service.message.websockettransport.AWebsocketConnection
 
- 
- All Implemented Interfaces:
- IWebSocketConnection
 - Direct Known Subclasses:
- WebSocketConnectionClient,- WebsocketConnectionClient2,- WebSocketConnectionServer
 
 public abstract class AWebsocketConnection extends java.lang.Object implements IWebSocketConnection Abstract websocket connection implements shared functionality between client and server.
- 
- 
Field SummaryFields Modifier and Type Field Description protected intbytesreceivedCurrent bytes received.protected ITransportHandler<IWebSocketConnection>handlerThe handler.protected booleanhasheaderFlag if the header was receiver: Needed because header can be null!protected byte[]headerHeader saved for handling once body arrives.protected intmaxmsgsizeCurrent maximum message size.protected static java.lang.StringNULL_MSG_COMMANDCommand to generate a null message (send as Text frame).protected WebSocketTransportAgentpojoagentThe agent.
 - 
Constructor SummaryConstructors Constructor Description AWebsocketConnection(ITransportHandler<IWebSocketConnection> handler)Creates the connection.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidhandleMessagePayload(byte[] payload)Handles a websocket message payload.- 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface jadex.platform.service.message.websockettransport.IWebSocketConnectionclose, forceClose, sendMessage
 
- 
 
- 
- 
- 
Field Detail- 
NULL_MSG_COMMANDprotected static final java.lang.String NULL_MSG_COMMAND Command to generate a null message (send as Text frame).- See Also:
- Constant Field Values
 
 - 
handlerprotected ITransportHandler<IWebSocketConnection> handler The handler.
 - 
hasheaderprotected boolean hasheader Flag if the header was receiver: Needed because header can be null!
 - 
headerprotected byte[] header Header saved for handling once body arrives.
 - 
maxmsgsizeprotected int maxmsgsize Current maximum message size.
 - 
pojoagentprotected WebSocketTransportAgent pojoagent The agent.
 - 
bytesreceivedprotected int bytesreceived Current bytes received.
 
- 
 - 
Constructor Detail- 
AWebsocketConnectionpublic AWebsocketConnection(ITransportHandler<IWebSocketConnection> handler) Creates the connection.
 
- 
 
-