Class WsFrameServer
- java.lang.Object
-
- org.apache.tomcat.websocket.WsFrameBase
-
- org.apache.tomcat.websocket.server.WsFrameServer
-
public class WsFrameServer extends WsFrameBase
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.tomcat.websocket.WsFrameBase
WsFrameBase.ReadState
-
-
Field Summary
-
Fields inherited from class org.apache.tomcat.websocket.WsFrameBase
inputBuffer, wsSession
-
-
Constructor Summary
Constructors Constructor Description WsFrameServer(SocketWrapperBase<?> socketWrapper, UpgradeInfo upgradeInfo, WsSession wsSession, Transformation transformation, java.lang.ClassLoader applicationClassLoader)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Log
getLog()
protected Transformation
getTransformation()
protected boolean
isMasked()
protected boolean
isOpen()
protected void
resumeProcessing()
This method will be invoked when the read operation is resumed.protected void
sendMessageBinary(java.nio.ByteBuffer msg, boolean last)
protected void
sendMessageText(boolean last)
protected void
updateStats(long payloadLength)
Hook for updating server side statistics.-
Methods inherited from class org.apache.tomcat.websocket.WsFrameBase
byteArrayToLong, changeReadState, changeReadState, getReadState, isSuspended, processInputBuffer, resume, suspend
-
-
-
-
Constructor Detail
-
WsFrameServer
public WsFrameServer(SocketWrapperBase<?> socketWrapper, UpgradeInfo upgradeInfo, WsSession wsSession, Transformation transformation, java.lang.ClassLoader applicationClassLoader)
-
-
Method Detail
-
updateStats
protected void updateStats(long payloadLength)
Description copied from class:WsFrameBase
Hook for updating server side statistics. Called on every frame received.- Overrides:
updateStats
in classWsFrameBase
- Parameters:
payloadLength
- Size of message payload
-
isMasked
protected boolean isMasked()
- Specified by:
isMasked
in classWsFrameBase
-
getTransformation
protected Transformation getTransformation()
- Overrides:
getTransformation
in classWsFrameBase
-
isOpen
protected boolean isOpen()
- Overrides:
isOpen
in classWsFrameBase
-
getLog
protected Log getLog()
- Specified by:
getLog
in classWsFrameBase
-
sendMessageText
protected void sendMessageText(boolean last) throws WsIOException
- Overrides:
sendMessageText
in classWsFrameBase
- Throws:
WsIOException
-
sendMessageBinary
protected void sendMessageBinary(java.nio.ByteBuffer msg, boolean last) throws WsIOException
- Overrides:
sendMessageBinary
in classWsFrameBase
- Throws:
WsIOException
-
resumeProcessing
protected void resumeProcessing()
Description copied from class:WsFrameBase
This method will be invoked when the read operation is resumed. As the suspend of the read operation can be invoked at any time, when implementing this method one should consider that there might still be data remaining into the internal buffers that needs to be processed before reading again from the socket.- Specified by:
resumeProcessing
in classWsFrameBase
-
-