Class StoneSerializer<T>

java.lang.Object
com.dropbox.core.stone.StoneSerializer<T>
Direct Known Subclasses:
CompositeSerializer

public abstract class StoneSerializer<T> extends Object
  • Constructor Details

    • StoneSerializer

      public StoneSerializer()
  • Method Details

    • serialize

      public String serialize(T value)
    • serialize

      public String serialize(T value, boolean pretty)
    • serialize

      public void serialize(T value, OutputStream out) throws IOException
      Throws:
      IOException
    • serialize

      public void serialize(T value, OutputStream out, boolean pretty) throws IOException
      Throws:
      IOException
    • deserialize

      public T deserialize(String json) throws com.fasterxml.jackson.core.JsonParseException
      Throws:
      com.fasterxml.jackson.core.JsonParseException
    • deserialize

      public T deserialize(InputStream json) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException
    • serialize

      public abstract void serialize(T value, com.fasterxml.jackson.core.JsonGenerator g) throws IOException, com.fasterxml.jackson.core.JsonGenerationException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonGenerationException
    • deserialize

      public abstract T deserialize(com.fasterxml.jackson.core.JsonParser p) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException
    • getStringValue

      protected static String getStringValue(com.fasterxml.jackson.core.JsonParser p) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException
    • expectField

      protected static void expectField(String name, com.fasterxml.jackson.core.JsonParser p) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException
    • expectStartObject

      protected static void expectStartObject(com.fasterxml.jackson.core.JsonParser p) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException
    • expectEndObject

      protected static void expectEndObject(com.fasterxml.jackson.core.JsonParser p) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException
    • expectStartArray

      protected static void expectStartArray(com.fasterxml.jackson.core.JsonParser p) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException
    • expectEndArray

      protected static void expectEndArray(com.fasterxml.jackson.core.JsonParser p) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException
    • skipValue

      protected static void skipValue(com.fasterxml.jackson.core.JsonParser p) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException
    • skipFields

      protected static void skipFields(com.fasterxml.jackson.core.JsonParser p) throws IOException, com.fasterxml.jackson.core.JsonParseException
      Throws:
      IOException
      com.fasterxml.jackson.core.JsonParseException