Class FakeRestRequest.FakeHttpRequest

java.lang.Object
org.elasticsearch.test.rest.FakeRestRequest.FakeHttpRequest
All Implemented Interfaces:
org.elasticsearch.http.HttpRequest
Enclosing class:
FakeRestRequest

public static class FakeRestRequest.FakeHttpRequest extends Object implements org.elasticsearch.http.HttpRequest
  • Constructor Details

    • FakeHttpRequest

      public FakeHttpRequest(org.elasticsearch.rest.RestRequest.Method method, String uri, org.elasticsearch.common.bytes.BytesReference content, Map<String,List<String>> headers)
  • Method Details

    • method

      public org.elasticsearch.rest.RestRequest.Method method()
      Specified by:
      method in interface org.elasticsearch.http.HttpRequest
    • uri

      public String uri()
      Specified by:
      uri in interface org.elasticsearch.http.HttpRequest
    • content

      public org.elasticsearch.common.bytes.BytesReference content()
      Specified by:
      content in interface org.elasticsearch.http.HttpRequest
    • getHeaders

      public Map<String,List<String>> getHeaders()
      Specified by:
      getHeaders in interface org.elasticsearch.http.HttpRequest
    • strictCookies

      public List<String> strictCookies()
      Specified by:
      strictCookies in interface org.elasticsearch.http.HttpRequest
    • protocolVersion

      public org.elasticsearch.http.HttpRequest.HttpVersion protocolVersion()
      Specified by:
      protocolVersion in interface org.elasticsearch.http.HttpRequest
    • removeHeader

      public org.elasticsearch.http.HttpRequest removeHeader(String header)
      Specified by:
      removeHeader in interface org.elasticsearch.http.HttpRequest
    • createResponse

      public org.elasticsearch.http.HttpResponse createResponse(org.elasticsearch.rest.RestStatus status, org.elasticsearch.common.bytes.BytesReference unused)
      Specified by:
      createResponse in interface org.elasticsearch.http.HttpRequest
    • release

      public void release()
      Specified by:
      release in interface org.elasticsearch.http.HttpRequest
    • releaseAndCopy

      public org.elasticsearch.http.HttpRequest releaseAndCopy()
      Specified by:
      releaseAndCopy in interface org.elasticsearch.http.HttpRequest
    • getInboundException

      public Exception getInboundException()
      Specified by:
      getInboundException in interface org.elasticsearch.http.HttpRequest