Class JettyJSONContext<M extends Message.Mutable>

java.lang.Object
org.cometd.common.JettyJSONContext<M>
Direct Known Subclasses:
JettyJSONContextClient, JettyJSONContextServer

public abstract class JettyJSONContext<M extends Message.Mutable> extends Object
  • Constructor Details

    • JettyJSONContext

      protected JettyJSONContext()
  • Method Details

    • getJSON

      public org.eclipse.jetty.util.ajax.JSON getJSON()
    • getAsyncJSONFactory

      public org.eclipse.jetty.util.ajax.AsyncJSON.Factory getAsyncJSONFactory()
    • newRoot

      protected abstract M newRoot()
    • newRootArray

      protected abstract M[] newRootArray(int size)
    • parse

      public M[] parse(Reader reader) throws ParseException
      Throws:
      ParseException
    • parse

      public M[] parse(String json) throws ParseException
      Throws:
      ParseException
    • newAsyncParser

      public JSONContext.AsyncParser newAsyncParser()
    • generate

      public String generate(M message)
    • generate

      public String generate(List<M> messages)
    • getParser

      public JSONContext.Parser getParser()
    • getGenerator

      public JSONContext.Generator getGenerator()
    • putConvertor

      public void putConvertor(String className, org.eclipse.jetty.util.ajax.JSON.Convertor convertor)