@Generated(value="software.amazon.awssdk:codegen") public final class SampledHTTPRequest extends Object implements SdkPojo, Serializable, ToCopyableBuilder<SampledHTTPRequest.Builder,SampledHTTPRequest>
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.
| Modifier and Type | Class and Description |
|---|---|
static interface |
SampledHTTPRequest.Builder |
| Modifier and Type | Method and Description |
|---|---|
String |
action()
The action that WAF applied to the request.
|
static SampledHTTPRequest.Builder |
builder() |
CaptchaResponse |
captchaResponse()
The
CAPTCHA response for the request. |
ChallengeResponse |
challengeResponse()
The
Challenge response for the request. |
boolean |
equals(Object obj) |
boolean |
equalsBySdkFields(Object obj) |
<T> Optional<T> |
getValueForField(String fieldName,
Class<T> clazz) |
int |
hashCode() |
boolean |
hasLabels()
For responses, this returns true if the service returned a value for the Labels property.
|
boolean |
hasRequestHeadersInserted()
For responses, this returns true if the service returned a value for the RequestHeadersInserted property.
|
List<Label> |
labels()
Labels applied to the web request by matching rules.
|
String |
overriddenAction()
Used only for rule group rules that have a rule action override in place in the web ACL.
|
HTTPRequest |
request()
A complex type that contains detailed information about the request.
|
List<HTTPHeader> |
requestHeadersInserted()
Custom request headers inserted by WAF into the request, according to the custom request configuration for the
matching rule action.
|
Integer |
responseCodeSent()
The response code that was sent for the request.
|
String |
ruleNameWithinRuleGroup()
The name of the
Rule that the request matched. |
List<SdkField<?>> |
sdkFields() |
static Class<? extends SampledHTTPRequest.Builder> |
serializableBuilderClass() |
Instant |
timestamp()
The time at which WAF received the request from your Amazon Web Services resource, in Unix time format (in
seconds).
|
SampledHTTPRequest.Builder |
toBuilder() |
String |
toString()
Returns a string representation of this object.
|
Long |
weight()
A value that indicates how one result in the response relates proportionally to other results in the response.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, waitcopypublic final HTTPRequest request()
A complex type that contains detailed information about the request.
public final 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.
2 represents roughly twice as many web
requests as a result that has a weight of 1.public final Instant timestamp()
The time at which WAF received the request from your Amazon Web Services resource, in Unix time format (in seconds).
public final String action()
The action that WAF applied to the request.
public final 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.
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 final boolean hasRequestHeadersInserted()
isEmpty() method on the
property). This is useful because the SDK will never return a null collection or map, but you may need to
differentiate between the service returning nothing (or null) and the service returning an empty collection or
map. For requests, this returns true if a value for the property was specified in the request builder, and false
if a value was not specified.public final List<HTTPHeader> requestHeadersInserted()
Custom request headers inserted by WAF into the request, according to the custom request configuration for the matching rule action.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasRequestHeadersInserted() method.
public final Integer responseCodeSent()
The response code that was sent for the request.
public final boolean hasLabels()
isEmpty() method on the property). This is
useful because the SDK will never return a null collection or map, but you may need to differentiate between the
service returning nothing (or null) and the service returning an empty collection or map. For requests, this
returns true if a value for the property was specified in the request builder, and false if a value was not
specified.public final List<Label> labels()
Labels applied to the web request by matching rules. 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.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasLabels() method.
For example, awswaf:111122223333:myRuleGroup:testRules:testNS1:testNS2:labelNameA or
awswaf:managed:aws:managed-rule-set:header:encoding:utf8.
public final CaptchaResponse captchaResponse()
The CAPTCHA response for the request.
CAPTCHA response for the request.public final ChallengeResponse challengeResponse()
The Challenge response for the request.
Challenge response for the request.public final String overriddenAction()
Used only for rule group rules that have a rule action override in place in the web ACL. This is the action that
the rule group rule is configured for, and not the action that was applied to the request. The action that WAF
applied is the Action value.
Action value.public SampledHTTPRequest.Builder toBuilder()
toBuilder in interface ToCopyableBuilder<SampledHTTPRequest.Builder,SampledHTTPRequest>public static SampledHTTPRequest.Builder builder()
public static Class<? extends SampledHTTPRequest.Builder> serializableBuilderClass()
public final boolean equalsBySdkFields(Object obj)
equalsBySdkFields in interface SdkPojopublic final String toString()
Copyright © 2023. All rights reserved.