Class SampledHTTPRequest

java.lang.Object
com.amazonaws.services.waf.model.SampledHTTPRequest
All Implemented Interfaces:
Serializable, Cloneable

public class SampledHTTPRequest extends Object implements Serializable, Cloneable

The response from a GetSampledRequests request includes a SampledHTTPRequests complex type that appears as SampledRequests in the response syntax. SampledHTTPRequests contains one SampledHTTPRequest object for each web request that is returned by GetSampledRequests.

See Also:
  • Constructor Details

    • SampledHTTPRequest

      public SampledHTTPRequest()
  • Method Details

    • setRequest

      public void setRequest(HTTPRequest request)

      A complex type that contains detailed information about the request.

      Parameters:
      request - A complex type that contains detailed information about the request.
    • getRequest

      public HTTPRequest getRequest()

      A complex type that contains detailed information about the request.

      Returns:
      A complex type that contains detailed information about the request.
    • withRequest

      public SampledHTTPRequest withRequest(HTTPRequest request)

      A complex type that contains detailed information about the request.

      Parameters:
      request - A complex type that contains detailed information about the request.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setWeight

      public void setWeight(Long weight)

      A value that indicates how one result in the response relates proportionally to other results in the response. A result that has a weight of 2 represents roughly twice as many CloudFront web requests as a result that has a weight of 1.

      Parameters:
      weight - A value that indicates how one result in the response relates proportionally to other results in the response. A result that has a weight of 2 represents roughly twice as many CloudFront web requests as a result that has a weight of 1.
    • getWeight

      public Long getWeight()

      A value that indicates how one result in the response relates proportionally to other results in the response. A result that has a weight of 2 represents roughly twice as many CloudFront web requests as a result that has a weight of 1.

      Returns:
      A value that indicates how one result in the response relates proportionally to other results in the response. A result that has a weight of 2 represents roughly twice as many CloudFront web requests as a result that has a weight of 1.
    • withWeight

      public SampledHTTPRequest withWeight(Long weight)

      A value that indicates how one result in the response relates proportionally to other results in the response. A result that has a weight of 2 represents roughly twice as many CloudFront web requests as a result that has a weight of 1.

      Parameters:
      weight - A value that indicates how one result in the response relates proportionally to other results in the response. A result that has a weight of 2 represents roughly twice as many CloudFront web requests as a result that has a weight of 1.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setTimestamp

      public void setTimestamp(Date timestamp)

      The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).

      Parameters:
      timestamp - The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).
    • getTimestamp

      public Date getTimestamp()

      The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).

      Returns:
      The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).
    • withTimestamp

      public SampledHTTPRequest withTimestamp(Date timestamp)

      The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).

      Parameters:
      timestamp - The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setAction

      public void setAction(String action)

      The action for the Rule that the request matched: ALLOW, BLOCK, or COUNT.

      Parameters:
      action - The action for the Rule that the request matched: ALLOW, BLOCK, or COUNT.
    • getAction

      public String getAction()

      The action for the Rule that the request matched: ALLOW, BLOCK, or COUNT.

      Returns:
      The action for the Rule that the request matched: ALLOW, BLOCK, or COUNT.
    • withAction

      public SampledHTTPRequest withAction(String action)

      The action for the Rule that the request matched: ALLOW, BLOCK, or COUNT.

      Parameters:
      action - The action for the Rule that the request matched: ALLOW, BLOCK, or COUNT.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • toString

      public String toString()
      Returns a string representation of this object; useful for testing and debugging.
      Overrides:
      toString in class Object
      Returns:
      A string representation of this object.
      See Also:
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • clone

      public SampledHTTPRequest clone()
      Overrides:
      clone in class Object