oracle.dbtools.plugin.api.json

## Interface JSONStreams

-     public interface JSONStreams

  Service for generating readable and writable JSON streams from character streams.
  Author:
    cdivilly

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `InputStream` | `inputStream(Iterator<JSONToken> reader)` Produce an `InputStream` on the fly from the specified `JSONToken` event stream
    `JSONReader` | `jsonReader(CharSequence text)` Wrap the specified character sequence in a `JSONReader` instance
    `JSONReader` | `jsonReader(InputStream stream)` Wrap the specified byte stream in a `JSONReader` instance
    `JSONReader` | `jsonReader(Readable stream)` Wrap the specified character stream in a `JSONReader` instance
    `JSONWriter` | `jsonWriter(Appendable stream)` Wrap the specified character stream in a `JSONWriter` instance.
    `JSONWriter` | `jsonWriter(OutputStream stream)` Wrap the specified byte stream in a `JSONWriter` instance.

- - ### Method Detail

    - #### inputStream

          InputStream inputStream(Iterator<JSONToken> reader)

      Produce an `InputStream` on the fly from the specified `JSONToken` event stream
      Parameters:
        `reader` - The `JSONToken` event stream to serialize
      Returns:
        `InputStream` containing the serialized representation of the input `JSONReader` stream

    - #### jsonWriter

          JSONWriter jsonWriter(OutputStream stream)

      Wrap the specified byte stream in a `JSONWriter` instance.
      Parameters:
        `stream` - The byte stream to write JSON to
      Returns:
        `JSONWriter` instance

    - #### jsonWriter

          JSONWriter jsonWriter(Appendable stream)

      Wrap the specified character stream in a `JSONWriter` instance.
      Parameters:
        `stream` - The character stream to write JSON to
      Returns:
        `JSONWriter` instance

    - #### jsonReader

          JSONReader jsonReader(Readable stream)

      Wrap the specified character stream in a `JSONReader` instance
      Parameters:
        `stream` - The character stream to read the JSON content from.
      Returns:
        `JSONReader` instance

    - #### jsonReader

          JSONReader jsonReader(CharSequence text)

      Wrap the specified character sequence in a `JSONReader` instance
      Parameters:
        `text` - The `CharSequence` to read the JSON content from.
      Returns:
        `JSONReader` instance

    - #### jsonReader

          JSONReader jsonReader(InputStream stream)

      Wrap the specified byte stream in a `JSONReader` instance
      Parameters:
        `stream` - The byte stream to read the JSON content from.
      Returns:
        `JSONReader` instance

Copyright © 2010, 2022, Oracle and/or its affiliates.