类 TextMessage

    • 构造器详细资料

      • TextMessage

        public TextMessage​(CharSequence payload)
        Create a new text WebSocket message from the given CharSequence payload.
        参数:
        payload - the non-null payload
      • TextMessage

        public TextMessage​(byte[] payload)
        Create a new text WebSocket message from the given byte[]. It is assumed the byte array can be encoded into an UTF-8 String.
        参数:
        payload - the non-null payload
      • TextMessage

        public TextMessage​(CharSequence payload,
                           boolean isLast)
        Create a new text WebSocket message with the given payload representing the full or partial message content. When the isLast boolean flag is set to false the message is sent as partial content and more partial messages will be expected until the boolean flag is set to true.
        参数:
        payload - the non-null payload
        isLast - whether this the last part of a series of partial messages