接口 WebSocketMessage<T>
public interface WebSocketMessage<T>
A message that can be handled or sent on a WebSocket connection.- 从以下版本开始:
- 4.0
- 作者:
- Rossen Stoyanchev
方法概要
所有方法 实例方法 抽象方法 修饰符和类型 方法 说明 T
getPayload()
Return the message payload (nevernull
).int
getPayloadLength()
Return the number of bytes contained in the message.boolean
isLast()
When partial message support is available and requested viaWebSocketHandler.supportsPartialMessages()
, this method returnstrue
if the current message is the last part of the complete WebSocket message sent by the client.
方法详细资料
getPayload
T getPayload()
Return the message payload (nevernull
).
getPayloadLength
int getPayloadLength()
Return the number of bytes contained in the message.
isLast
boolean isLast()
When partial message support is available and requested viaWebSocketHandler.supportsPartialMessages()
, this method returnstrue
if the current message is the last part of the complete WebSocket message sent by the client. Otherwisefalse
is returned if partial message support is either not available or not enabled.