Code example for JsonPrimitive

      return new MessageWrapper(seqno, type, message);
    public static String serialize(String type,int seqno,  JsonElement message) {
      JsonObject o = new JsonObject();
      o.add("messageType", new JsonPrimitive(type));
      o.add("sequenceNumber", new JsonPrimitive(seqno));
      o.add("message", message);
      return o.toString();
  private final ProtoCallback callback;
  private final Gson gson = new Gson();
  private final ProtoSerializer serializer;
   * Constructs a new WebSocketChannel, using the callback to handle any 
   * incoming messages.