Class CGIRequestBuilder


  • public class CGIRequestBuilder
    extends java.lang.Object
    Abstraction layer above the Apache RequestBuilder to use for building requests to interact with cgi-services
    • Constructor Summary

      Constructors 
      Constructor Description
      CGIRequestBuilder​(java.net.URI uri)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      org.apache.http.client.methods.HttpUriRequest buildFileResolverRequest​(boolean exactFilename)
      Adds the configurations to communicate with the file resolver service to the request builder and builds the request.
      org.apache.http.client.methods.HttpUriRequest buildRequest​(java.net.URI uri)
      Builds the request with the specified uri.
      org.apache.http.client.methods.HttpUriRequest buildWRSRequest​(long offset)
      Adds the configurations to communicate with the warc record service (WRS) to the request builder and builds the request.
      • Methods inherited from class java.lang.Object

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

      • CGIRequestBuilder

        public CGIRequestBuilder​(java.net.URI uri)
        Constructor.
        Parameters:
        uri - The full URI with a path to a specific service's cgi-script and its parameters/queries.
    • Method Detail

      • buildWRSRequest

        public org.apache.http.client.methods.HttpUriRequest buildWRSRequest​(long offset)
        Adds the configurations to communicate with the warc record service (WRS) to the request builder and builds the request.
        Parameters:
        offset - The offset in the warc record to read from.
        Returns:
        A request to execute against WRS.
      • buildFileResolverRequest

        public org.apache.http.client.methods.HttpUriRequest buildFileResolverRequest​(boolean exactFilename)
        Adds the configurations to communicate with the file resolver service to the request builder and builds the request.
        Parameters:
        exactFilename - Boolean specifying whether to resolve the path to an exact filename or default to regex.
        Returns:
        A request to execute against the file resolver.
      • buildRequest

        public org.apache.http.client.methods.HttpUriRequest buildRequest​(java.net.URI uri)
        Builds the request with the specified uri.
        Parameters:
        uri - URI of the service to interact with.
        Returns:
        A request to execute.