Package org.cometd.server.ext
Class BinarySessionExtension
java.lang.Object
org.cometd.bayeux.server.ServerSession.Extension.Adapter
org.cometd.server.ext.BinarySessionExtension
- All Implemented Interfaces:
ServerSession.Extension
public class BinarySessionExtension extends ServerSession.Extension.Adapter
An extension that encodes/decodes binary data for a ServerSession
.
- See Also:
BinaryExtension
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.cometd.bayeux.server.ServerSession.Extension
ServerSession.Extension.Adapter
-
Constructor Summary
Constructors Constructor Description BinarySessionExtension(BayeuxServer bayeuxServer)
BinarySessionExtension(BayeuxServer bayeuxServer, boolean decodeToByteBuffer)
-
Method Summary
Modifier and Type Method Description boolean
rcv(ServerSession session, ServerMessage.Mutable message)
Callback method invoked every time a normal message is incoming.ServerMessage
send(ServerSession session, ServerMessage message)
Callback method invoked every time a normal message is outgoing.Methods inherited from class org.cometd.bayeux.server.ServerSession.Extension.Adapter
rcvMeta, sendMeta
-
Constructor Details
-
Method Details
-
rcv
Description copied from interface:ServerSession.Extension
Callback method invoked every time a normal message is incoming.
- Specified by:
rcv
in interfaceServerSession.Extension
- Overrides:
rcv
in classServerSession.Extension.Adapter
- Parameters:
session
- the session that sent the messagemessage
- the incoming message- Returns:
- true if message processing should continue, false if it should stop
-
send
Description copied from interface:ServerSession.Extension
Callback method invoked every time a normal message is outgoing.
- Specified by:
send
in interfaceServerSession.Extension
- Overrides:
send
in classServerSession.Extension.Adapter
- Parameters:
session
- the session receiving the messagemessage
- the outgoing message- Returns:
- The message to send or null to not send the message
-