Interface HttpRequest

All Known Implementing Classes:
HttpRequestImpl

public interface HttpRequest
Class representing an HTTP request. Contains details such as the HTTP method, URL, headers, and body.
  • Method Details

    • getMethod

      HttpMethod getMethod()
      Gets the HTTP method of the request.
      Returns:
      the HTTP method
    • getURL

      String getURL()
      Gets the full URL of the request.
      Returns:
      the URL as a string
    • getPath

      String getPath()
      Gets the path of the request (excluding query parameters).
      Returns:
      the path as a string
    • pathParameters

      Map<String,String> pathParameters()
      Gets the path parameters extracted from the URL.
      Returns:
      a map of path parameter names to their values
    • getQueryParameters

      Map<String,String> getQueryParameters()
      Gets the query parameters from the URL.
      Returns:
      a map of query parameter names to their values
    • getHeaders

      Map<String,String> getHeaders()
      Gets the headers of the request.
      Returns:
      a map of header names to their values
    • getBody

      String getBody()
      Gets the body of the request.
      Returns:
      the body as a string