Class StringMessageSink
java.lang.Object
org.eclipse.jetty.websocket.core.messages.AbstractMessageSink
org.eclipse.jetty.websocket.core.messages.StringMessageSink
- All Implemented Interfaces:
- MessageSink
A MessageSink implementation that accumulates TEXT frames
into a message that is then delivered to the application function
passed to the constructor in the form of a String.
- 
Constructor SummaryConstructorsConstructorDescriptionStringMessageSink(CoreSession session, MethodHandle methodHandle, boolean autoDemand) Creates a newStringMessageSink.
- 
Method SummaryMethods inherited from class AbstractMessageSinkautoDemand, getCoreSession, getMethodHandle, isAutoDemand
- 
Constructor Details- 
StringMessageSinkCreates a newStringMessageSink.- Parameters:
- session- the WebSocket session
- methodHandle- the application function to invoke when a new message has been assembled
- autoDemand- whether this- MessageSinkmanages demand automatically
 
 
- 
- 
Method Details- 
acceptDescription copied from interface:MessageSinkConsumes the WebSocket frame, possibly asynchronously when this method has returned. The callback argument must be completed when the frame payload is consumed. The demand for more frames must be explicitly invoked, or arranged to be invoked asynchronously, by the implementation of this method, by calling CoreSession.demand().- Parameters:
- frame- the frame to consume
- callback- the callback to complete when the frame is consumed
 
- 
failDescription copied from interface:MessageSinkFails this MessageSinkwith the given cause.- Parameters:
- failure- the cause of the failure
 
 
-