Class HttpExchangeReader

    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static HttpExchange fromJson​(java.io.InputStream in)
      Read a single HTTP exchange from a JSON formatted string in the HTTP types format.
      static HttpExchange fromJson​(java.io.Reader in)
      Read a single HTTP exchange from a JSON formatted string in the HTTP types format.
      static HttpExchange fromJson​(java.lang.String in)
      Read a single HTTP exchange from a JSON formatted string in the HTTP types format.
      static java.util.stream.Stream<HttpExchange> fromJsonLines​(java.io.InputStream in)
      Parse a stream of HTTP exchanges from a HTTP Types JSON Lines formatted input.
      static java.util.stream.Stream<HttpExchange> fromJsonLines​(java.io.Reader reader)
      Parse a stream of HTTP exchanges from a HTTP Types JSON Lines formatted input.
      static java.util.stream.Stream<HttpExchange> fromJsonLines​(java.lang.String jsonLines)
      Parse a stream of HTTP exchanges from a HTTP Types JSON Lines formatted input.
      • Methods inherited from class java.lang.Object

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

      • fromJson

        public static HttpExchange fromJson​(java.lang.String in)
        Read a single HTTP exchange from a JSON formatted string in the HTTP types format.
        Parameters:
        in - the JSON representation of a single HTTP exchange
        Returns:
        the parsed HTTP exchange
        See Also:
        fromJson(InputStream), fromJson(Reader)
      • fromJson

        public static HttpExchange fromJson​(java.io.InputStream in)
                                     throws java.io.IOException
        Read a single HTTP exchange from a JSON formatted string in the HTTP types format.
        Parameters:
        in - the JSON representation of a single HTTP exchange
        Returns:
        the parsed HTTP exchange
        Throws:
        java.io.IOException - if there is an I/O problem reading the input
        See Also:
        fromJson(String), fromJson(Reader)
      • fromJson

        public static HttpExchange fromJson​(java.io.Reader in)
                                     throws java.io.IOException
        Read a single HTTP exchange from a JSON formatted string in the HTTP types format.
        Parameters:
        in - the JSON representation of a single HTTP exchange
        Returns:
        the parsed HTTP exchange
        Throws:
        java.io.IOException - if there is an I/O problem reading the input
        See Also:
        fromJson(String), fromJson(InputStream)
      • fromJsonLines

        public static java.util.stream.Stream<HttpExchange> fromJsonLines​(java.lang.String jsonLines)
        Parse a stream of HTTP exchanges from a HTTP Types JSON Lines formatted input.
        Parameters:
        jsonLines - the input in HTTP TYPES JSON Lines format
        Returns:
        a stream of HTTP Exchanges defined by this archive
        See Also:
        fromJsonLines(Reader), fromJsonLines(InputStream)
      • fromJsonLines

        public static java.util.stream.Stream<HttpExchange> fromJsonLines​(java.io.InputStream in)
                                                                   throws java.io.IOException
        Parse a stream of HTTP exchanges from a HTTP Types JSON Lines formatted input.
        Parameters:
        in - the input in HTTP TYPES JSON Lines format
        Returns:
        a stream of HTTP Exchanges defined by this archive
        Throws:
        java.io.IOException - if there is a I/O problem reading the input
        See Also:
        fromJsonLines(Reader), fromJsonLines(String)
      • fromJsonLines

        public static java.util.stream.Stream<HttpExchange> fromJsonLines​(java.io.Reader reader)
                                                                   throws java.io.IOException
        Parse a stream of HTTP exchanges from a HTTP Types JSON Lines formatted input.
        Parameters:
        reader - the input in HTTP Types JSON Lines format
        Returns:
        a stream of HTTP Exchanges defined by this archive
        Throws:
        java.io.IOException - if there is an I/O problem reading the input.
        See Also:
        fromJsonLines(InputStream), fromJsonLines(String)