Class JsonReaderFactoryImpl

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private BufferPool bufferPool  
      private java.util.Map<java.lang.String,​?> config  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      JsonReader createReader​(java.io.InputStream in)
      Creates a JSON reader from a byte stream.
      JsonReader createReader​(java.io.InputStream in, java.nio.charset.Charset charset)
      Creates a JSON reader from a byte stream.
      JsonReader createReader​(java.io.Reader reader)
      Creates a JSON reader from a character stream.
      java.util.Map<java.lang.String,​?> getConfigInUse()
      Returns read-only map of supported provider specific configuration properties that are used to configure the created JSON readers.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • config

        private final java.util.Map<java.lang.String,​?> config
    • Constructor Detail

      • JsonReaderFactoryImpl

        JsonReaderFactoryImpl​(BufferPool bufferPool)
    • Method Detail

      • createReader

        public JsonReader createReader​(java.io.Reader reader)
        Description copied from interface: JsonReaderFactory
        Creates a JSON reader from a character stream. The reader is configured with the factory configuration.
        Specified by:
        createReader in interface JsonReaderFactory
        Parameters:
        reader - a reader from which JSON is to be read
        Returns:
        a JSON reader
      • createReader

        public JsonReader createReader​(java.io.InputStream in)
        Description copied from interface: JsonReaderFactory
        Creates a JSON reader from a byte stream. The character encoding of the stream is determined as described in RFC 7159. The reader is configured with the factory configuration.
        Specified by:
        createReader in interface JsonReaderFactory
        Parameters:
        in - a byte stream from which JSON is to be read
        Returns:
        a JSON reader
      • createReader

        public JsonReader createReader​(java.io.InputStream in,
                                       java.nio.charset.Charset charset)
        Description copied from interface: JsonReaderFactory
        Creates a JSON reader from a byte stream. The bytes of the stream are decoded to characters using the specified charset. The reader is configured with the factory configuration.
        Specified by:
        createReader in interface JsonReaderFactory
        Parameters:
        in - a byte stream from which JSON is to be read
        charset - a charset
        Returns:
        a JSON reader
      • getConfigInUse

        public java.util.Map<java.lang.String,​?> getConfigInUse()
        Description copied from interface: JsonReaderFactory
        Returns read-only map of supported provider specific configuration properties that are used to configure the created JSON readers. If there are any specified configuration properties that are not supported by the provider, they won't be part of the returned map.
        Specified by:
        getConfigInUse in interface JsonReaderFactory
        Returns:
        a map of supported provider specific properties that are used to configure the readers. The map be empty but not null.