Class DefaultSchemaClient

  • All Implemented Interfaces:
    java.util.function.Function<java.lang.String,​java.io.InputStream>, SchemaClient

    public class DefaultSchemaClient
    extends java.lang.Object
    implements SchemaClient
    A SchemaClient implementation which uses URL for reading the remote content.
    • Method Summary

      Modifier and Type Method Description
      java.io.InputStream get​(java.lang.String url)
      Returns a stream to be used for reading the remote content (response body) of the URL.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.util.function.Function

        andThen, compose
    • Constructor Detail

      • DefaultSchemaClient

        public DefaultSchemaClient()
    • Method Detail

      • get

        public java.io.InputStream get​(java.lang.String url)
        Description copied from interface: SchemaClient
        Returns a stream to be used for reading the remote content (response body) of the URL. In the case of a HTTP URL, implementations are expected send HTTP GET requests and the response is expected to be represented in UTF-8 character set.
        Specified by:
        get in interface SchemaClient
        Parameters:
        url - the URL of the remote resource
        Returns:
        the input stream of the response