Class RestQuery

java.lang.Object
net.serenitybdd.core.rest.RestQuery

public class RestQuery
extends java.lang.Object
  • Constructor Details

    • RestQuery

      public RestQuery​(RestMethod method, java.lang.String path)
  • Method Details

    • withParameters

      public RestQuery withParameters​(java.util.List<java.lang.Object> parameters)
    • withParameters

      public RestQuery withParameters​(java.util.Map<java.lang.String,​?> parameterMap)
    • withResponse

      public RestQuery withResponse​(java.lang.String responseBody)
    • withStatusCode

      public RestQuery withStatusCode​(java.lang.Integer statusCode)
    • withContent

      public RestQuery withContent​(java.lang.String content)
    • withContentType

      public RestQuery withContentType​(java.lang.String contentType)
    • withResponseCookies

      public RestQuery withResponseCookies​(java.lang.String responseCookies)
    • withResponseHeaders

      public RestQuery withResponseHeaders​(java.lang.String responseHeaders)
    • withRequestCookies

      public RestQuery withRequestCookies​(java.lang.String requestCookies)
    • withRequestHeaders

      public RestQuery withRequestHeaders​(java.lang.String requestHeaders)
    • getMethod

      public RestMethod getMethod()
    • getPath

      public java.lang.String getPath()
    • getParameters

      public java.util.Optional<? extends java.util.List<java.lang.Object>> getParameters()
    • getParameterMap

      public java.util.Optional<? extends java.util.Map<java.lang.String,​?>> getParameterMap()
    • getResponseBody

      public java.lang.String getResponseBody()
    • getContent

      public java.lang.String getContent()
    • getContentType

      public java.lang.String getContentType()
    • getStatusCode

      public java.lang.Integer getStatusCode()
    • getRequestHeaders

      public java.lang.String getRequestHeaders()
    • getRequestCookies

      public java.lang.String getRequestCookies()
    • getResponseHeaders

      public java.lang.String getResponseHeaders()
    • getResponseCookies

      public java.lang.String getResponseCookies()
    • hasParameters

      public boolean hasParameters()
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object
    • getFormattedQuery

      public java.lang.String getFormattedQuery()
    • withMethod

      public static RestQuery.RestQueryBuilder withMethod​(RestMethod method)