Interface RestRequestBuilder


  • public interface RestRequestBuilder
    Represent a REST request being constructed.
    • Method Detail

      • setRequestUrl

        RestRequestBuilder setRequestUrl​(java.net.URL requestUrl)
        Set the request URL
        Parameters:
        requestUrl - the request url
        Returns:
        this request builder
      • setCookieHeader

        RestRequestBuilder setCookieHeader​(java.lang.String cookieHeader)
        Set the cookie header
        Parameters:
        cookieHeader - the cookie header value
        Returns:
        this request builder
      • addHeader

        RestRequestBuilder addHeader​(java.lang.String name,
                                     java.lang.String value)
        Add a header to the rest request
        Parameters:
        name - the header name
        value - the header value
        Returns:
        this request builder
      • setContent

        RestRequestBuilder setContent​(java.lang.String contentType,
                                      java.lang.Object content,
                                      byte[] encodedContent)
        Set the content of the rest request.
        Parameters:
        contentType - the content type to be used
        content - the object that represents the content. This is used in tracing.
        encodedContent - the content, encoded as a byte[], according to the contentType
        Returns:
        this request builder
      • getApi

        java.lang.String getApi()
        Returns:
        the associated API for this rest request
      • getOperationId

        java.lang.String getOperationId()
        Returns:
        the associated operation-id for this rest request