Interface SpiJsonWriter

All Superinterfaces:
io.ebean.text.json.JsonWriter
All Known Implementing Classes:
WriteJson

public interface SpiJsonWriter extends io.ebean.text.json.JsonWriter
Internal API extensions for JSON writing of Bean properties.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Start a Many.
    void
    beginAssocManyMap(String name, boolean elementCollection)
    Start a Many.
    void
    beginAssocOne(String name, io.ebean.bean.EntityBean bean)
    Start an assoc one path.
    void
    End a Many.
    void
    endAssocManyMap(boolean elementCollection)
    End a Many.
    void
    End an assoc one path.
    void
    Flush the buffer.
    Return true if the many property should be included.
    boolean
    Return true if the value is a parent bean.
    void
    Pop the parent of a ToMany.
    void
    pushParentBeanMany(io.ebean.bean.EntityBean bean)
    Push the parent bean of a ToMany.
    void
    toJson(String name, Collection<?> collection)
    Write the collection.
    <T> void
    writeBean(BeanDescriptor<T> desc, io.ebean.bean.EntityBean bean)
    Write the bean properties.
    void
    Write value using underlying Jaskson object mapper if available.

    Methods inherited from interface io.ebean.text.json.JsonWriter

    gen, isIncludeEmpty, isIncludeNull, writeBinary, writeBinaryField, writeBoolean, writeBooleanField, writeEndArray, writeEndObject, writeFieldName, writeNull, writeNullField, writeNumber, writeNumber, writeNumber, writeNumber, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeNumberField, writeRaw, writeRawValue, writeStartArray, writeStartArray, writeStartObject, writeStartObject, writeString, writeStringField
  • Method Details

    • flush

      void flush() throws IOException
      Flush the buffer.
      Throws:
      IOException
    • parentBean

      boolean parentBean(Object value)
      Return true if the value is a parent bean.
    • beginAssocOne

      void beginAssocOne(String name, io.ebean.bean.EntityBean bean)
      Start an assoc one path.
    • endAssocOne

      void endAssocOne()
      End an assoc one path.
    • includeMany

      Boolean includeMany(String name)
      Return true if the many property should be included.
    • pushParentBeanMany

      void pushParentBeanMany(io.ebean.bean.EntityBean bean)
      Push the parent bean of a ToMany.
    • popParentBeanMany

      void popParentBeanMany()
      Pop the parent of a ToMany.
    • toJson

      void toJson(String name, Collection<?> collection)
      Write the collection.
    • beginAssocMany

      void beginAssocMany(String name)
      Start a Many.
    • endAssocMany

      void endAssocMany()
      End a Many.
    • beginAssocManyMap

      void beginAssocManyMap(String name, boolean elementCollection)
      Start a Many.
    • endAssocManyMap

      void endAssocManyMap(boolean elementCollection)
      End a Many.
    • writeValueUsingObjectMapper

      void writeValueUsingObjectMapper(String name, Object value)
      Write value using underlying Jaskson object mapper if available.
    • writeBean

      <T> void writeBean(BeanDescriptor<T> desc, io.ebean.bean.EntityBean bean)
      Write the bean properties.