@NotThreadSafe public abstract class AmazonWebServiceRequest extends Object
Modifier and Type | Field and Description |
---|---|
static AmazonWebServiceRequest |
NOOP |
Constructor and Description |
---|
AmazonWebServiceRequest() |
Modifier and Type | Method and Description |
---|---|
Map<String,String> |
copyPrivateRequestParameters()
Internal only method for accessing private, internal request parameters.
|
Map<String,String> |
getCustomRequestHeaders()
Returns an immutable map of custom header names to header values.
|
ProgressListener |
getGeneralProgressListener()
Returns the optional progress listener for receiving updates about the
progress of the request.
|
int |
getReadLimit()
Convenient method to return the optional read limit for mark-and-reset
during retries.
|
RequestClientOptions |
getRequestClientOptions()
Gets the options stored with this request object.
|
AWSCredentials |
getRequestCredentials()
Returns the optional credentials to use to sign this request, overriding
the default credentials set at the client level.
|
RequestMetricCollector |
getRequestMetricCollector()
Returns a request level metric collector; or null if not specified.
|
String |
putCustomRequestHeader(String name,
String value)
Put a new custom header to the map of custom header names to custom
header values, and return the previous value if the header has already
been set in this map.
|
void |
setGeneralProgressListener(ProgressListener progressListener)
Sets the optional progress listener for receiving updates about the
progress of the request.
|
void |
setRequestCredentials(AWSCredentials credentials)
Sets the optional credentials to use for this request, overriding the
default credentials set at the client level.
|
void |
setRequestMetricCollector(RequestMetricCollector requestMetricCollector)
Sets a request level request metric collector which takes precedence over
the ones at the http client level and AWS SDK level.
|
<T extends AmazonWebServiceRequest> |
withGeneralProgressListener(ProgressListener progressListener)
Sets the optional progress listener for receiving updates about the
progress of the request, and returns a reference to this object so that
method calls can be chained together.
|
<T extends AmazonWebServiceRequest> |
withRequestMetricCollector(RequestMetricCollector metricCollector)
Specifies a request level metric collector which takes precedence over
the ones at the http client level and AWS SDK level.
|
public static final AmazonWebServiceRequest NOOP
public void setRequestCredentials(AWSCredentials credentials)
credentials
- The optional AWS security credentials to use for this request,
overriding the default credentials set at the client level.public AWSCredentials getRequestCredentials()
public Map<String,String> copyPrivateRequestParameters()
public RequestClientOptions getRequestClientOptions()
public RequestMetricCollector getRequestMetricCollector()
public void setRequestMetricCollector(RequestMetricCollector requestMetricCollector)
public <T extends AmazonWebServiceRequest> T withRequestMetricCollector(RequestMetricCollector metricCollector)
public void setGeneralProgressListener(ProgressListener progressListener)
progressListener
- The new progress listener.public ProgressListener getGeneralProgressListener()
public <T extends AmazonWebServiceRequest> T withGeneralProgressListener(ProgressListener progressListener)
progressListener
- The new progress listener.public Map<String,String> getCustomRequestHeaders()
public String putCustomRequestHeader(String name, String value)
NOTE: Custom header values set via this method will overwrite any conflicting values coming from the request parameters.
name
- The name of the header to addvalue
- The value of the header to addpublic final int getReadLimit()
Copyright © 2015. All rights reserved.