Class AddPermissionRequest
- java.lang.Object
-
- com.amazonaws.AmazonWebServiceRequest
-
- com.amazonaws.services.sqs.model.AddPermissionRequest
-
- All Implemented Interfaces:
ReadLimitInfo
,Serializable
,Cloneable
public class AddPermissionRequest extends AmazonWebServiceRequest implements Serializable, Cloneable
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class com.amazonaws.AmazonWebServiceRequest
NOOP
-
-
Constructor Summary
Constructors Constructor Description AddPermissionRequest()
Default constructor for AddPermissionRequest object.AddPermissionRequest(String queueUrl, String label, List<String> aWSAccountIds, List<String> actions)
Constructs a new AddPermissionRequest object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AddPermissionRequest
clone()
Creates a shallow clone of this request.boolean
equals(Object obj)
List<String>
getActions()
The action the client wants to allow for the specified principal.List<String>
getAWSAccountIds()
The AWS account number of the principal who will be given permission.String
getLabel()
The unique identification of the permission you're setting (e.g.,AliceSendMessage
).String
getQueueUrl()
The URL of the Amazon SQS queue to take action on.int
hashCode()
void
setActions(Collection<String> actions)
The action the client wants to allow for the specified principal.void
setAWSAccountIds(Collection<String> aWSAccountIds)
The AWS account number of the principal who will be given permission.void
setLabel(String label)
The unique identification of the permission you're setting (e.g.,AliceSendMessage
).void
setQueueUrl(String queueUrl)
The URL of the Amazon SQS queue to take action on.String
toString()
Returns a string representation of this object; useful for testing and debugging.AddPermissionRequest
withActions(String... actions)
The action the client wants to allow for the specified principal.AddPermissionRequest
withActions(Collection<String> actions)
The action the client wants to allow for the specified principal.AddPermissionRequest
withAWSAccountIds(String... aWSAccountIds)
The AWS account number of the principal who will be given permission.AddPermissionRequest
withAWSAccountIds(Collection<String> aWSAccountIds)
The AWS account number of the principal who will be given permission.AddPermissionRequest
withLabel(String label)
The unique identification of the permission you're setting (e.g.,AliceSendMessage
).AddPermissionRequest
withQueueUrl(String queueUrl)
The URL of the Amazon SQS queue to take action on.-
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
-
AddPermissionRequest
public AddPermissionRequest()
Default constructor for AddPermissionRequest object. Callers should use the setter or fluent setter (with...) methods to initialize the object after creating it.
-
AddPermissionRequest
public AddPermissionRequest(String queueUrl, String label, List<String> aWSAccountIds, List<String> actions)
Constructs a new AddPermissionRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.- Parameters:
queueUrl
- The URL of the Amazon SQS queue to take action on.Queue URLs are case-sensitive.
label
- The unique identification of the permission you're setting (e.g.,AliceSendMessage
). Constraints: Maximum 80 characters; alphanumeric characters, hyphens (-), and underscores (_) are allowed.aWSAccountIds
- The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide.actions
- The action the client wants to allow for the specified principal. The following are valid values:* | SendMessage | ReceiveMessage | DeleteMessage | ChangeMessageVisibility | GetQueueAttributes | GetQueueUrl
. For more information about these actions, see Understanding Permissions in the Amazon SQS Developer Guide.Specifying
SendMessage
,DeleteMessage
, orChangeMessageVisibility
for theActionName.n
also grants permissions for the corresponding batch versions of those actions:SendMessageBatch
,DeleteMessageBatch
, andChangeMessageVisibilityBatch
.
-
-
Method Detail
-
setQueueUrl
public void setQueueUrl(String queueUrl)
The URL of the Amazon SQS queue to take action on.
Queue URLs are case-sensitive.
- Parameters:
queueUrl
- The URL of the Amazon SQS queue to take action on.Queue URLs are case-sensitive.
-
getQueueUrl
public String getQueueUrl()
The URL of the Amazon SQS queue to take action on.
Queue URLs are case-sensitive.
- Returns:
- The URL of the Amazon SQS queue to take action on.
Queue URLs are case-sensitive.
-
withQueueUrl
public AddPermissionRequest withQueueUrl(String queueUrl)
The URL of the Amazon SQS queue to take action on.
Queue URLs are case-sensitive.
- Parameters:
queueUrl
- The URL of the Amazon SQS queue to take action on.Queue URLs are case-sensitive.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setLabel
public void setLabel(String label)
The unique identification of the permission you're setting (e.g.,
AliceSendMessage
). Constraints: Maximum 80 characters; alphanumeric characters, hyphens (-), and underscores (_) are allowed.- Parameters:
label
- The unique identification of the permission you're setting (e.g.,AliceSendMessage
). Constraints: Maximum 80 characters; alphanumeric characters, hyphens (-), and underscores (_) are allowed.
-
getLabel
public String getLabel()
The unique identification of the permission you're setting (e.g.,
AliceSendMessage
). Constraints: Maximum 80 characters; alphanumeric characters, hyphens (-), and underscores (_) are allowed.- Returns:
- The unique identification of the permission you're setting (e.g.,
AliceSendMessage
). Constraints: Maximum 80 characters; alphanumeric characters, hyphens (-), and underscores (_) are allowed.
-
withLabel
public AddPermissionRequest withLabel(String label)
The unique identification of the permission you're setting (e.g.,
AliceSendMessage
). Constraints: Maximum 80 characters; alphanumeric characters, hyphens (-), and underscores (_) are allowed.- Parameters:
label
- The unique identification of the permission you're setting (e.g.,AliceSendMessage
). Constraints: Maximum 80 characters; alphanumeric characters, hyphens (-), and underscores (_) are allowed.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
getAWSAccountIds
public List<String> getAWSAccountIds()
The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide.
- Returns:
- The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide.
-
setAWSAccountIds
public void setAWSAccountIds(Collection<String> aWSAccountIds)
The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide.
- Parameters:
aWSAccountIds
- The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide.
-
withAWSAccountIds
public AddPermissionRequest withAWSAccountIds(String... aWSAccountIds)
The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide.
NOTE: This method appends the values to the existing list (if any). Use
setAWSAccountIds(java.util.Collection)
orwithAWSAccountIds(java.util.Collection)
if you want to override the existing values.- Parameters:
aWSAccountIds
- The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
withAWSAccountIds
public AddPermissionRequest withAWSAccountIds(Collection<String> aWSAccountIds)
The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide.
- Parameters:
aWSAccountIds
- The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
getActions
public List<String> getActions()
The action the client wants to allow for the specified principal. The following are valid values:
* | SendMessage | ReceiveMessage | DeleteMessage | ChangeMessageVisibility | GetQueueAttributes | GetQueueUrl
. For more information about these actions, see Understanding Permissions in the Amazon SQS Developer Guide.Specifying
SendMessage
,DeleteMessage
, orChangeMessageVisibility
for theActionName.n
also grants permissions for the corresponding batch versions of those actions:SendMessageBatch
,DeleteMessageBatch
, andChangeMessageVisibilityBatch
.- Returns:
- The action the client wants to allow for the specified principal.
The following are valid values:
* | SendMessage | ReceiveMessage | DeleteMessage | ChangeMessageVisibility | GetQueueAttributes | GetQueueUrl
. For more information about these actions, see Understanding Permissions in the Amazon SQS Developer Guide.Specifying
SendMessage
,DeleteMessage
, orChangeMessageVisibility
for theActionName.n
also grants permissions for the corresponding batch versions of those actions:SendMessageBatch
,DeleteMessageBatch
, andChangeMessageVisibilityBatch
.
-
setActions
public void setActions(Collection<String> actions)
The action the client wants to allow for the specified principal. The following are valid values:
* | SendMessage | ReceiveMessage | DeleteMessage | ChangeMessageVisibility | GetQueueAttributes | GetQueueUrl
. For more information about these actions, see Understanding Permissions in the Amazon SQS Developer Guide.Specifying
SendMessage
,DeleteMessage
, orChangeMessageVisibility
for theActionName.n
also grants permissions for the corresponding batch versions of those actions:SendMessageBatch
,DeleteMessageBatch
, andChangeMessageVisibilityBatch
.- Parameters:
actions
- The action the client wants to allow for the specified principal. The following are valid values:* | SendMessage | ReceiveMessage | DeleteMessage | ChangeMessageVisibility | GetQueueAttributes | GetQueueUrl
. For more information about these actions, see Understanding Permissions in the Amazon SQS Developer Guide.Specifying
SendMessage
,DeleteMessage
, orChangeMessageVisibility
for theActionName.n
also grants permissions for the corresponding batch versions of those actions:SendMessageBatch
,DeleteMessageBatch
, andChangeMessageVisibilityBatch
.
-
withActions
public AddPermissionRequest withActions(String... actions)
The action the client wants to allow for the specified principal. The following are valid values:
* | SendMessage | ReceiveMessage | DeleteMessage | ChangeMessageVisibility | GetQueueAttributes | GetQueueUrl
. For more information about these actions, see Understanding Permissions in the Amazon SQS Developer Guide.Specifying
SendMessage
,DeleteMessage
, orChangeMessageVisibility
for theActionName.n
also grants permissions for the corresponding batch versions of those actions:SendMessageBatch
,DeleteMessageBatch
, andChangeMessageVisibilityBatch
.NOTE: This method appends the values to the existing list (if any). Use
setActions(java.util.Collection)
orwithActions(java.util.Collection)
if you want to override the existing values.- Parameters:
actions
- The action the client wants to allow for the specified principal. The following are valid values:* | SendMessage | ReceiveMessage | DeleteMessage | ChangeMessageVisibility | GetQueueAttributes | GetQueueUrl
. For more information about these actions, see Understanding Permissions in the Amazon SQS Developer Guide.Specifying
SendMessage
,DeleteMessage
, orChangeMessageVisibility
for theActionName.n
also grants permissions for the corresponding batch versions of those actions:SendMessageBatch
,DeleteMessageBatch
, andChangeMessageVisibilityBatch
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
withActions
public AddPermissionRequest withActions(Collection<String> actions)
The action the client wants to allow for the specified principal. The following are valid values:
* | SendMessage | ReceiveMessage | DeleteMessage | ChangeMessageVisibility | GetQueueAttributes | GetQueueUrl
. For more information about these actions, see Understanding Permissions in the Amazon SQS Developer Guide.Specifying
SendMessage
,DeleteMessage
, orChangeMessageVisibility
for theActionName.n
also grants permissions for the corresponding batch versions of those actions:SendMessageBatch
,DeleteMessageBatch
, andChangeMessageVisibilityBatch
.- Parameters:
actions
- The action the client wants to allow for the specified principal. The following are valid values:* | SendMessage | ReceiveMessage | DeleteMessage | ChangeMessageVisibility | GetQueueAttributes | GetQueueUrl
. For more information about these actions, see Understanding Permissions in the Amazon SQS Developer Guide.Specifying
SendMessage
,DeleteMessage
, orChangeMessageVisibility
for theActionName.n
also grants permissions for the corresponding batch versions of those actions:SendMessageBatch
,DeleteMessageBatch
, andChangeMessageVisibilityBatch
.- 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 AddPermissionRequest 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()
-
-