Class MessageEncoder

java.lang.Object
com.jbstrap.core.websocket.MessageEncoder
All Implemented Interfaces:
javax.websocket.Encoder, javax.websocket.Encoder.Text<Object>

public class MessageEncoder extends Object implements javax.websocket.Encoder.Text<Object>
Since:
4.0
Author:
JBStrap
  • Nested Class Summary

    Nested classes/interfaces inherited from interface javax.websocket.Encoder

    javax.websocket.Encoder.Binary<T extends Object>, javax.websocket.Encoder.BinaryStream<T extends Object>, javax.websocket.Encoder.Text<T extends Object>, javax.websocket.Encoder.TextStream<T extends Object>
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Encode message object to the JSON object
    void
    init(javax.websocket.EndpointConfig arg0)

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • MessageEncoder

      public MessageEncoder()
  • Method Details

    • encode

      public String encode(Object msg)
      Encode message object to the JSON object
      Specified by:
      encode in interface javax.websocket.Encoder.Text<Object>
    • destroy

      public void destroy()
      Specified by:
      destroy in interface javax.websocket.Encoder
    • init

      public void init(javax.websocket.EndpointConfig arg0)
      Specified by:
      init in interface javax.websocket.Encoder