@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class SampledHTTPRequest extends Object implements Serializable, Cloneable, StructuredPojo
Represents a single sampled web request. The response from GetSampledRequests includes a
SampledHTTPRequests
complex type that appears as SampledRequests
in the response syntax.
SampledHTTPRequests
contains an array of SampledHTTPRequest
objects.
Constructor and Description |
---|
SampledHTTPRequest() |
Modifier and Type | Method and Description |
---|---|
SampledHTTPRequest |
clone() |
boolean |
equals(Object obj) |
String |
getAction()
The action for the
Rule that the request matched: ALLOW , BLOCK , or
COUNT . |
List<Label> |
getLabels()
Labels applied to the web request by matching rules.
|
HTTPRequest |
getRequest()
A complex type that contains detailed information about the request.
|
List<HTTPHeader> |
getRequestHeadersInserted()
Custom request headers inserted by AWS WAF into the request, according to the custom request configuration for
the matching rule action.
|
Integer |
getResponseCodeSent()
The response code that was sent for the request.
|
String |
getRuleNameWithinRuleGroup()
The name of the
Rule that the request matched. |
Date |
getTimestamp()
The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).
|
Long |
getWeight()
A value that indicates how one result in the response relates proportionally to other results in the response.
|
int |
hashCode() |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setAction(String action)
The action for the
Rule that the request matched: ALLOW , BLOCK , or
COUNT . |
void |
setLabels(Collection<Label> labels)
Labels applied to the web request by matching rules.
|
void |
setRequest(HTTPRequest request)
A complex type that contains detailed information about the request.
|
void |
setRequestHeadersInserted(Collection<HTTPHeader> requestHeadersInserted)
Custom request headers inserted by AWS WAF into the request, according to the custom request configuration for
the matching rule action.
|
void |
setResponseCodeSent(Integer responseCodeSent)
The response code that was sent for the request.
|
void |
setRuleNameWithinRuleGroup(String ruleNameWithinRuleGroup)
The name of the
Rule that the request matched. |
void |
setTimestamp(Date timestamp)
The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).
|
void |
setWeight(Long weight)
A value that indicates how one result in the response relates proportionally to other results in the response.
|
String |
toString()
Returns a string representation of this object.
|
SampledHTTPRequest |
withAction(String action)
The action for the
Rule that the request matched: ALLOW , BLOCK , or
COUNT . |
SampledHTTPRequest |
withLabels(Collection<Label> labels)
Labels applied to the web request by matching rules.
|
SampledHTTPRequest |
withLabels(Label... labels)
Labels applied to the web request by matching rules.
|
SampledHTTPRequest |
withRequest(HTTPRequest request)
A complex type that contains detailed information about the request.
|
SampledHTTPRequest |
withRequestHeadersInserted(Collection<HTTPHeader> requestHeadersInserted)
Custom request headers inserted by AWS WAF into the request, according to the custom request configuration for
the matching rule action.
|
SampledHTTPRequest |
withRequestHeadersInserted(HTTPHeader... requestHeadersInserted)
Custom request headers inserted by AWS WAF into the request, according to the custom request configuration for
the matching rule action.
|
SampledHTTPRequest |
withResponseCodeSent(Integer responseCodeSent)
The response code that was sent for the request.
|
SampledHTTPRequest |
withRuleNameWithinRuleGroup(String ruleNameWithinRuleGroup)
The name of the
Rule that the request matched. |
SampledHTTPRequest |
withTimestamp(Date timestamp)
The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).
|
SampledHTTPRequest |
withWeight(Long weight)
A value that indicates how one result in the response relates proportionally to other results in the response.
|
public void setRequest(HTTPRequest request)
A complex type that contains detailed information about the request.
request
- A complex type that contains detailed information about the request.public HTTPRequest getRequest()
A complex type that contains detailed information about the request.
public SampledHTTPRequest withRequest(HTTPRequest request)
A complex type that contains detailed information about the request.
request
- A complex type that contains detailed information about the request.public void setWeight(Long weight)
A value that indicates how one result in the response relates proportionally to other results in the response.
For example, a result that has a weight of 2
represents roughly twice as many web requests as a
result that has a weight of 1
.
weight
- A value that indicates how one result in the response relates proportionally to other results in the
response. For example, a result that has a weight of 2
represents roughly twice as many web
requests as a result that has a weight of 1
.public Long getWeight()
A value that indicates how one result in the response relates proportionally to other results in the response.
For example, a result that has a weight of 2
represents roughly twice as many web requests as a
result that has a weight of 1
.
2
represents roughly twice as many web
requests as a result that has a weight of 1
.public SampledHTTPRequest withWeight(Long weight)
A value that indicates how one result in the response relates proportionally to other results in the response.
For example, a result that has a weight of 2
represents roughly twice as many web requests as a
result that has a weight of 1
.
weight
- A value that indicates how one result in the response relates proportionally to other results in the
response. For example, a result that has a weight of 2
represents roughly twice as many web
requests as a result that has a weight of 1
.public void setTimestamp(Date timestamp)
The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).
timestamp
- The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).public Date getTimestamp()
The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).
public SampledHTTPRequest withTimestamp(Date timestamp)
The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).
timestamp
- The time at which AWS WAF received the request from your AWS resource, in Unix time format (in seconds).public void setAction(String action)
The action for the Rule
that the request matched: ALLOW
, BLOCK
, or
COUNT
.
action
- The action for the Rule
that the request matched: ALLOW
, BLOCK
, or
COUNT
.public String getAction()
The action for the Rule
that the request matched: ALLOW
, BLOCK
, or
COUNT
.
Rule
that the request matched: ALLOW
, BLOCK
, or
COUNT
.public SampledHTTPRequest withAction(String action)
The action for the Rule
that the request matched: ALLOW
, BLOCK
, or
COUNT
.
action
- The action for the Rule
that the request matched: ALLOW
, BLOCK
, or
COUNT
.public void setRuleNameWithinRuleGroup(String ruleNameWithinRuleGroup)
The name of the Rule
that the request matched. For managed rule groups, the format for this name is
<vendor name>#<managed rule group name>#<rule name>
. For your own rule groups, the
format for this name is <rule group name>#<rule name>
. If the rule is not in a rule
group, this field is absent.
ruleNameWithinRuleGroup
- The name of the Rule
that the request matched. For managed rule groups, the format for this
name is <vendor name>#<managed rule group name>#<rule name>
. For your own
rule groups, the format for this name is <rule group name>#<rule name>
. If the
rule is not in a rule group, this field is absent.public String getRuleNameWithinRuleGroup()
The name of the Rule
that the request matched. For managed rule groups, the format for this name is
<vendor name>#<managed rule group name>#<rule name>
. For your own rule groups, the
format for this name is <rule group name>#<rule name>
. If the rule is not in a rule
group, this field is absent.
Rule
that the request matched. For managed rule groups, the format for this
name is <vendor name>#<managed rule group name>#<rule name>
. For your own
rule groups, the format for this name is <rule group name>#<rule name>
. If the
rule is not in a rule group, this field is absent.public SampledHTTPRequest withRuleNameWithinRuleGroup(String ruleNameWithinRuleGroup)
The name of the Rule
that the request matched. For managed rule groups, the format for this name is
<vendor name>#<managed rule group name>#<rule name>
. For your own rule groups, the
format for this name is <rule group name>#<rule name>
. If the rule is not in a rule
group, this field is absent.
ruleNameWithinRuleGroup
- The name of the Rule
that the request matched. For managed rule groups, the format for this
name is <vendor name>#<managed rule group name>#<rule name>
. For your own
rule groups, the format for this name is <rule group name>#<rule name>
. If the
rule is not in a rule group, this field is absent.public List<HTTPHeader> getRequestHeadersInserted()
Custom request headers inserted by AWS WAF into the request, according to the custom request configuration for the matching rule action.
public void setRequestHeadersInserted(Collection<HTTPHeader> requestHeadersInserted)
Custom request headers inserted by AWS WAF into the request, according to the custom request configuration for the matching rule action.
requestHeadersInserted
- Custom request headers inserted by AWS WAF into the request, according to the custom request configuration
for the matching rule action.public SampledHTTPRequest withRequestHeadersInserted(HTTPHeader... requestHeadersInserted)
Custom request headers inserted by AWS WAF into the request, according to the custom request configuration for the matching rule action.
NOTE: This method appends the values to the existing list (if any). Use
setRequestHeadersInserted(java.util.Collection)
or
withRequestHeadersInserted(java.util.Collection)
if you want to override the existing values.
requestHeadersInserted
- Custom request headers inserted by AWS WAF into the request, according to the custom request configuration
for the matching rule action.public SampledHTTPRequest withRequestHeadersInserted(Collection<HTTPHeader> requestHeadersInserted)
Custom request headers inserted by AWS WAF into the request, according to the custom request configuration for the matching rule action.
requestHeadersInserted
- Custom request headers inserted by AWS WAF into the request, according to the custom request configuration
for the matching rule action.public void setResponseCodeSent(Integer responseCodeSent)
The response code that was sent for the request.
responseCodeSent
- The response code that was sent for the request.public Integer getResponseCodeSent()
The response code that was sent for the request.
public SampledHTTPRequest withResponseCodeSent(Integer responseCodeSent)
The response code that was sent for the request.
responseCodeSent
- The response code that was sent for the request.public List<Label> getLabels()
Labels applied to the web request by matching rules. AWS WAF applies fully qualified labels to matching web requests. A fully qualified label is the concatenation of a label namespace and a rule label. The rule's rule group or web ACL defines the label namespace.
For example, awswaf:111122223333:myRuleGroup:testRules:testNS1:testNS2:labelNameA
or
awswaf:managed:aws:managed-rule-set:header:encoding:utf8
.
For example, awswaf:111122223333:myRuleGroup:testRules:testNS1:testNS2:labelNameA
or
awswaf:managed:aws:managed-rule-set:header:encoding:utf8
.
public void setLabels(Collection<Label> labels)
Labels applied to the web request by matching rules. AWS WAF applies fully qualified labels to matching web requests. A fully qualified label is the concatenation of a label namespace and a rule label. The rule's rule group or web ACL defines the label namespace.
For example, awswaf:111122223333:myRuleGroup:testRules:testNS1:testNS2:labelNameA
or
awswaf:managed:aws:managed-rule-set:header:encoding:utf8
.
labels
- Labels applied to the web request by matching rules. AWS WAF applies fully qualified labels to matching
web requests. A fully qualified label is the concatenation of a label namespace and a rule label. The
rule's rule group or web ACL defines the label namespace.
For example, awswaf:111122223333:myRuleGroup:testRules:testNS1:testNS2:labelNameA
or
awswaf:managed:aws:managed-rule-set:header:encoding:utf8
.
public SampledHTTPRequest withLabels(Label... labels)
Labels applied to the web request by matching rules. AWS WAF applies fully qualified labels to matching web requests. A fully qualified label is the concatenation of a label namespace and a rule label. The rule's rule group or web ACL defines the label namespace.
For example, awswaf:111122223333:myRuleGroup:testRules:testNS1:testNS2:labelNameA
or
awswaf:managed:aws:managed-rule-set:header:encoding:utf8
.
NOTE: This method appends the values to the existing list (if any). Use
setLabels(java.util.Collection)
or withLabels(java.util.Collection)
if you want to override the
existing values.
labels
- Labels applied to the web request by matching rules. AWS WAF applies fully qualified labels to matching
web requests. A fully qualified label is the concatenation of a label namespace and a rule label. The
rule's rule group or web ACL defines the label namespace.
For example, awswaf:111122223333:myRuleGroup:testRules:testNS1:testNS2:labelNameA
or
awswaf:managed:aws:managed-rule-set:header:encoding:utf8
.
public SampledHTTPRequest withLabels(Collection<Label> labels)
Labels applied to the web request by matching rules. AWS WAF applies fully qualified labels to matching web requests. A fully qualified label is the concatenation of a label namespace and a rule label. The rule's rule group or web ACL defines the label namespace.
For example, awswaf:111122223333:myRuleGroup:testRules:testNS1:testNS2:labelNameA
or
awswaf:managed:aws:managed-rule-set:header:encoding:utf8
.
labels
- Labels applied to the web request by matching rules. AWS WAF applies fully qualified labels to matching
web requests. A fully qualified label is the concatenation of a label namespace and a rule label. The
rule's rule group or web ACL defines the label namespace.
For example, awswaf:111122223333:myRuleGroup:testRules:testNS1:testNS2:labelNameA
or
awswaf:managed:aws:managed-rule-set:header:encoding:utf8
.
public String toString()
toString
in class Object
Object.toString()
public SampledHTTPRequest clone()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
- Implementation of ProtocolMarshaller
used to marshall this object's data.