Class JSONObjectWriter<T extends net.minidev.json.JSONAware>

    • Constructor Detail

      • JSONObjectWriter

        public JSONObjectWriter​(Writer writer,
                                KeyExtractor<T> keyExtractor)
        Deprecated.
        Creates a new JSON object writer.
        Parameters:
        writer - Writer for the JSON object. Must not be null.
        keyExtractor - Extracts or determines a JSON object key from the appended elements. Must not be null.
    • Method Detail

      • writeStart

        public void writeStart()
        Deprecated.
        Writes out the opening '{' of the JSON object.
      • accept

        public void accept​(T element)
        Deprecated.
        Specified by:
        accept in interface Consumer<T extends net.minidev.json.JSONAware>
      • append

        public void append​(T element)
        Deprecated.
        Description copied from interface: Appendable
        Appends the specified element.
        Specified by:
        append in interface Appendable<T extends net.minidev.json.JSONAware>
        Parameters:
        element - The element to append. May be null.
      • writeEnd

        public void writeEnd()
        Deprecated.
        Writes out the closing '}' of the JSON object and closes the writer.