Class UploadArchiveRequest
- java.lang.Object
-
- com.amazonaws.AmazonWebServiceRequest
-
- com.amazonaws.services.glacier.model.UploadArchiveRequest
-
- All Implemented Interfaces:
ReadLimitInfo
,Serializable
,Cloneable
public class UploadArchiveRequest extends AmazonWebServiceRequest implements Serializable, Cloneable
Provides options to add an archive to a vault.
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class com.amazonaws.AmazonWebServiceRequest
NOOP
-
-
Constructor Summary
Constructors Constructor Description UploadArchiveRequest()
Default constructor for UploadArchiveRequest object.UploadArchiveRequest(String vaultName, String archiveDescription, String checksum, InputStream body)
Constructs a new UploadArchiveRequest object.UploadArchiveRequest(String vaultName, String accountId, String archiveDescription, String checksum, InputStream body)
Constructs a new UploadArchiveRequest object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UploadArchiveRequest
clone()
Creates a shallow clone of this request.boolean
equals(Object obj)
String
getAccountId()
TheAccountId
value is the AWS account ID of the account that owns the vault.String
getArchiveDescription()
The optional description of the archive you are uploading.InputStream
getBody()
The data to upload.String
getChecksum()
The SHA256 tree hash of the data being uploaded.Long
getContentLength()
The content length of the archive to upload.String
getVaultName()
The name of the vault.int
hashCode()
void
setAccountId(String accountId)
TheAccountId
value is the AWS account ID of the account that owns the vault.void
setArchiveDescription(String archiveDescription)
The optional description of the archive you are uploading.void
setBody(InputStream body)
The data to upload.void
setChecksum(String checksum)
The SHA256 tree hash of the data being uploaded.void
setContentLength(Long contentLength)
The content length of the archive to upload.void
setVaultName(String vaultName)
The name of the vault.String
toString()
Returns a string representation of this object; useful for testing and debugging.UploadArchiveRequest
withAccountId(String accountId)
TheAccountId
value is the AWS account ID of the account that owns the vault.UploadArchiveRequest
withArchiveDescription(String archiveDescription)
The optional description of the archive you are uploading.UploadArchiveRequest
withBody(InputStream body)
The data to upload.UploadArchiveRequest
withChecksum(String checksum)
The SHA256 tree hash of the data being uploaded.UploadArchiveRequest
withContentLength(Long contentLength)
The content length of the archive to upload.UploadArchiveRequest
withVaultName(String vaultName)
The name of the vault.-
Methods inherited from class com.amazonaws.AmazonWebServiceRequest
copyBaseTo, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestCredentialsProvider, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestCredentialsProvider, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
-
-
-
-
Constructor Detail
-
UploadArchiveRequest
public UploadArchiveRequest()
Default constructor for UploadArchiveRequest object. Callers should use the setter or fluent setter (with...) methods to initialize the object after creating it.
-
UploadArchiveRequest
public UploadArchiveRequest(String vaultName, String archiveDescription, String checksum, InputStream body)
Constructs a new UploadArchiveRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.- Parameters:
vaultName
- The name of the vault.archiveDescription
- The optional description of the archive you are uploading.checksum
- The SHA256 tree hash of the data being uploaded.body
- The data to upload.
-
UploadArchiveRequest
public UploadArchiveRequest(String vaultName, String accountId, String archiveDescription, String checksum, InputStream body)
Constructs a new UploadArchiveRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.- Parameters:
vaultName
- The name of the vault.accountId
- TheAccountId
value is the AWS account ID of the account that owns the vault. You can either specify an AWS account ID or optionally a single apos-
apos (hyphen), in which case Amazon Glacier uses the AWS account ID associated with the credentials used to sign the request. If you use an account ID, do not include any hyphens (apos-apos) in the ID.archiveDescription
- The optional description of the archive you are uploading.checksum
- The SHA256 tree hash of the data being uploaded.body
- The data to upload.
-
-
Method Detail
-
setVaultName
public void setVaultName(String vaultName)
The name of the vault.
- Parameters:
vaultName
- The name of the vault.
-
getVaultName
public String getVaultName()
The name of the vault.
- Returns:
- The name of the vault.
-
withVaultName
public UploadArchiveRequest withVaultName(String vaultName)
The name of the vault.
- Parameters:
vaultName
- The name of the vault.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setAccountId
public void setAccountId(String accountId)
The
AccountId
value is the AWS account ID of the account that owns the vault. You can either specify an AWS account ID or optionally a single apos-
apos (hyphen), in which case Amazon Glacier uses the AWS account ID associated with the credentials used to sign the request. If you use an account ID, do not include any hyphens (apos-apos) in the ID.- Parameters:
accountId
- TheAccountId
value is the AWS account ID of the account that owns the vault. You can either specify an AWS account ID or optionally a single apos-
apos (hyphen), in which case Amazon Glacier uses the AWS account ID associated with the credentials used to sign the request. If you use an account ID, do not include any hyphens (apos-apos) in the ID.
-
getAccountId
public String getAccountId()
The
AccountId
value is the AWS account ID of the account that owns the vault. You can either specify an AWS account ID or optionally a single apos-
apos (hyphen), in which case Amazon Glacier uses the AWS account ID associated with the credentials used to sign the request. If you use an account ID, do not include any hyphens (apos-apos) in the ID.- Returns:
- The
AccountId
value is the AWS account ID of the account that owns the vault. You can either specify an AWS account ID or optionally a single apos-
apos (hyphen), in which case Amazon Glacier uses the AWS account ID associated with the credentials used to sign the request. If you use an account ID, do not include any hyphens (apos-apos) in the ID.
-
withAccountId
public UploadArchiveRequest withAccountId(String accountId)
The
AccountId
value is the AWS account ID of the account that owns the vault. You can either specify an AWS account ID or optionally a single apos-
apos (hyphen), in which case Amazon Glacier uses the AWS account ID associated with the credentials used to sign the request. If you use an account ID, do not include any hyphens (apos-apos) in the ID.- Parameters:
accountId
- TheAccountId
value is the AWS account ID of the account that owns the vault. You can either specify an AWS account ID or optionally a single apos-
apos (hyphen), in which case Amazon Glacier uses the AWS account ID associated with the credentials used to sign the request. If you use an account ID, do not include any hyphens (apos-apos) in the ID.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setArchiveDescription
public void setArchiveDescription(String archiveDescription)
The optional description of the archive you are uploading.
- Parameters:
archiveDescription
- The optional description of the archive you are uploading.
-
getArchiveDescription
public String getArchiveDescription()
The optional description of the archive you are uploading.
- Returns:
- The optional description of the archive you are uploading.
-
withArchiveDescription
public UploadArchiveRequest withArchiveDescription(String archiveDescription)
The optional description of the archive you are uploading.
- Parameters:
archiveDescription
- The optional description of the archive you are uploading.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setChecksum
public void setChecksum(String checksum)
The SHA256 tree hash of the data being uploaded.
- Parameters:
checksum
- The SHA256 tree hash of the data being uploaded.
-
getChecksum
public String getChecksum()
The SHA256 tree hash of the data being uploaded.
- Returns:
- The SHA256 tree hash of the data being uploaded.
-
withChecksum
public UploadArchiveRequest withChecksum(String checksum)
The SHA256 tree hash of the data being uploaded.
- Parameters:
checksum
- The SHA256 tree hash of the data being uploaded.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setBody
public void setBody(InputStream body)
The data to upload.
- Parameters:
body
- The data to upload.
-
getBody
public InputStream getBody()
The data to upload.
- Returns:
- The data to upload.
-
withBody
public UploadArchiveRequest withBody(InputStream body)
The data to upload.
- Parameters:
body
- The data to upload.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setContentLength
public void setContentLength(Long contentLength)
The content length of the archive to upload.- Parameters:
contentLength
- The content length of the archive to upload.
-
getContentLength
public Long getContentLength()
The content length of the archive to upload.- Returns:
- The content length of the archive to upload.
-
withContentLength
public UploadArchiveRequest withContentLength(Long contentLength)
The content length of the archive to upload.- Parameters:
contentLength
- The content length of the archive to upload.- 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 classObject
- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
clone
public UploadArchiveRequest clone()
Description copied from class:AmazonWebServiceRequest
Creates a shallow clone of this request. Explicitly does not clone the deep structure of the request object.- Overrides:
clone
in classAmazonWebServiceRequest
- See Also:
Object.clone()
-
-