@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class HTTPRequest extends Object implements Serializable, Cloneable, StructuredPojo
Part of the response from GetSampledRequests. This is a complex type that appears as Request
in
the response syntax. HTTPRequest
contains information about one of the web requests.
Constructor and Description |
---|
HTTPRequest() |
Modifier and Type | Method and Description |
---|---|
HTTPRequest |
clone() |
boolean |
equals(Object obj) |
String |
getClientIP()
The IP address that the request originated from.
|
String |
getCountry()
The two-letter country code for the country that the request originated from.
|
List<HTTPHeader> |
getHeaders()
A complex type that contains the name and value for each header in the sampled web request.
|
String |
getHTTPVersion()
The HTTP version specified in the sampled web request, for example,
HTTP/1.1 . |
String |
getMethod()
The HTTP method specified in the sampled web request.
|
String |
getURI()
The URI path of the request, which identifies the resource, for example,
/images/daily-ad.jpg . |
int |
hashCode() |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setClientIP(String clientIP)
The IP address that the request originated from.
|
void |
setCountry(String country)
The two-letter country code for the country that the request originated from.
|
void |
setHeaders(Collection<HTTPHeader> headers)
A complex type that contains the name and value for each header in the sampled web request.
|
void |
setHTTPVersion(String hTTPVersion)
The HTTP version specified in the sampled web request, for example,
HTTP/1.1 . |
void |
setMethod(String method)
The HTTP method specified in the sampled web request.
|
void |
setURI(String uRI)
The URI path of the request, which identifies the resource, for example,
/images/daily-ad.jpg . |
String |
toString()
Returns a string representation of this object.
|
HTTPRequest |
withClientIP(String clientIP)
The IP address that the request originated from.
|
HTTPRequest |
withCountry(String country)
The two-letter country code for the country that the request originated from.
|
HTTPRequest |
withHeaders(Collection<HTTPHeader> headers)
A complex type that contains the name and value for each header in the sampled web request.
|
HTTPRequest |
withHeaders(HTTPHeader... headers)
A complex type that contains the name and value for each header in the sampled web request.
|
HTTPRequest |
withHTTPVersion(String hTTPVersion)
The HTTP version specified in the sampled web request, for example,
HTTP/1.1 . |
HTTPRequest |
withMethod(String method)
The HTTP method specified in the sampled web request.
|
HTTPRequest |
withURI(String uRI)
The URI path of the request, which identifies the resource, for example,
/images/daily-ad.jpg . |
public void setClientIP(String clientIP)
The IP address that the request originated from. If the web ACL is associated with a CloudFront distribution, this is the value of one of the following fields in CloudFront access logs:
c-ip
, if the viewer did not use an HTTP proxy or a load balancer to send the request
x-forwarded-for
, if the viewer did use an HTTP proxy or a load balancer to send the request
clientIP
- The IP address that the request originated from. If the web ACL is associated with a CloudFront
distribution, this is the value of one of the following fields in CloudFront access logs:
c-ip
, if the viewer did not use an HTTP proxy or a load balancer to send the request
x-forwarded-for
, if the viewer did use an HTTP proxy or a load balancer to send the request
public String getClientIP()
The IP address that the request originated from. If the web ACL is associated with a CloudFront distribution, this is the value of one of the following fields in CloudFront access logs:
c-ip
, if the viewer did not use an HTTP proxy or a load balancer to send the request
x-forwarded-for
, if the viewer did use an HTTP proxy or a load balancer to send the request
c-ip
, if the viewer did not use an HTTP proxy or a load balancer to send the request
x-forwarded-for
, if the viewer did use an HTTP proxy or a load balancer to send the request
public HTTPRequest withClientIP(String clientIP)
The IP address that the request originated from. If the web ACL is associated with a CloudFront distribution, this is the value of one of the following fields in CloudFront access logs:
c-ip
, if the viewer did not use an HTTP proxy or a load balancer to send the request
x-forwarded-for
, if the viewer did use an HTTP proxy or a load balancer to send the request
clientIP
- The IP address that the request originated from. If the web ACL is associated with a CloudFront
distribution, this is the value of one of the following fields in CloudFront access logs:
c-ip
, if the viewer did not use an HTTP proxy or a load balancer to send the request
x-forwarded-for
, if the viewer did use an HTTP proxy or a load balancer to send the request
public void setCountry(String country)
The two-letter country code for the country that the request originated from. For a current list of country codes, see the Wikipedia entry ISO 3166-1 alpha-2.
country
- The two-letter country code for the country that the request originated from. For a current list of
country codes, see the Wikipedia entry ISO
3166-1 alpha-2.public String getCountry()
The two-letter country code for the country that the request originated from. For a current list of country codes, see the Wikipedia entry ISO 3166-1 alpha-2.
public HTTPRequest withCountry(String country)
The two-letter country code for the country that the request originated from. For a current list of country codes, see the Wikipedia entry ISO 3166-1 alpha-2.
country
- The two-letter country code for the country that the request originated from. For a current list of
country codes, see the Wikipedia entry ISO
3166-1 alpha-2.public void setURI(String uRI)
The URI path of the request, which identifies the resource, for example, /images/daily-ad.jpg
.
uRI
- The URI path of the request, which identifies the resource, for example, /images/daily-ad.jpg
.public String getURI()
The URI path of the request, which identifies the resource, for example, /images/daily-ad.jpg
.
/images/daily-ad.jpg
.public HTTPRequest withURI(String uRI)
The URI path of the request, which identifies the resource, for example, /images/daily-ad.jpg
.
uRI
- The URI path of the request, which identifies the resource, for example, /images/daily-ad.jpg
.public void setMethod(String method)
The HTTP method specified in the sampled web request.
method
- The HTTP method specified in the sampled web request.public String getMethod()
The HTTP method specified in the sampled web request.
public HTTPRequest withMethod(String method)
The HTTP method specified in the sampled web request.
method
- The HTTP method specified in the sampled web request.public void setHTTPVersion(String hTTPVersion)
The HTTP version specified in the sampled web request, for example, HTTP/1.1
.
hTTPVersion
- The HTTP version specified in the sampled web request, for example, HTTP/1.1
.public String getHTTPVersion()
The HTTP version specified in the sampled web request, for example, HTTP/1.1
.
HTTP/1.1
.public HTTPRequest withHTTPVersion(String hTTPVersion)
The HTTP version specified in the sampled web request, for example, HTTP/1.1
.
hTTPVersion
- The HTTP version specified in the sampled web request, for example, HTTP/1.1
.public List<HTTPHeader> getHeaders()
A complex type that contains the name and value for each header in the sampled web request.
public void setHeaders(Collection<HTTPHeader> headers)
A complex type that contains the name and value for each header in the sampled web request.
headers
- A complex type that contains the name and value for each header in the sampled web request.public HTTPRequest withHeaders(HTTPHeader... headers)
A complex type that contains the name and value for each header in the sampled web request.
NOTE: This method appends the values to the existing list (if any). Use
setHeaders(java.util.Collection)
or withHeaders(java.util.Collection)
if you want to override
the existing values.
headers
- A complex type that contains the name and value for each header in the sampled web request.public HTTPRequest withHeaders(Collection<HTTPHeader> headers)
A complex type that contains the name and value for each header in the sampled web request.
headers
- A complex type that contains the name and value for each header in the sampled web request.public String toString()
toString
in class Object
Object.toString()
public HTTPRequest clone()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
- Implementation of ProtocolMarshaller
used to marshall this object's data.