public class PutGroupPolicyRequest extends AmazonWebServiceRequest implements Serializable, Cloneable
PutGroupPolicy operation
.
Adds (or updates) an inline policy document that is embedded in the specified group.
A user can also have managed policies attached to it. To attach a managed policy to a group, use AttachGroupPolicy. To create a new managed policy, use CreatePolicy. For information about policies, refer to Managed Policies and Inline Policies in the IAM User Guide .
For information about limits on the number of inline policies that you can embed in a group, see Limitations on IAM Entities in the IAM User Guide .
NOTE:Because policy documents can be large, you should use POST rather than GET when calling PutGroupPolicy. For general information about using the Query API with IAM, go to Making Query Requests in the Using IAM guide.
NOOP
Constructor and Description |
---|
PutGroupPolicyRequest()
Default constructor for a new PutGroupPolicyRequest object.
|
PutGroupPolicyRequest(String groupName,
String policyName,
String policyDocument)
Constructs a new PutGroupPolicyRequest object.
|
Modifier and Type | Method and Description |
---|---|
PutGroupPolicyRequest |
clone()
Creates a shallow clone of this request.
|
boolean |
equals(Object obj) |
String |
getGroupName()
The name of the group to associate the policy with.
|
String |
getPolicyDocument()
The policy document.
|
String |
getPolicyName()
The name of the policy document.
|
int |
hashCode() |
void |
setGroupName(String groupName)
The name of the group to associate the policy with.
|
void |
setPolicyDocument(String policyDocument)
The policy document.
|
void |
setPolicyName(String policyName)
The name of the policy document.
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
PutGroupPolicyRequest |
withGroupName(String groupName)
The name of the group to associate the policy with.
|
PutGroupPolicyRequest |
withPolicyDocument(String policyDocument)
The policy document.
|
PutGroupPolicyRequest |
withPolicyName(String policyName)
The name of the policy document.
|
copyBaseTo, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
public PutGroupPolicyRequest()
public PutGroupPolicyRequest(String groupName, String policyName, String policyDocument)
groupName
- The name of the group to associate the policy with.policyName
- The name of the policy document.policyDocument
- The policy document.public String getGroupName()
Constraints:
Length: 1 - 128
Pattern: [\w+=,.@-]+
public void setGroupName(String groupName)
Constraints:
Length: 1 - 128
Pattern: [\w+=,.@-]+
groupName
- The name of the group to associate the policy with.public PutGroupPolicyRequest withGroupName(String groupName)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 128
Pattern: [\w+=,.@-]+
groupName
- The name of the group to associate the policy with.public String getPolicyName()
Constraints:
Length: 1 - 128
Pattern: [\w+=,.@-]+
public void setPolicyName(String policyName)
Constraints:
Length: 1 - 128
Pattern: [\w+=,.@-]+
policyName
- The name of the policy document.public PutGroupPolicyRequest withPolicyName(String policyName)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 128
Pattern: [\w+=,.@-]+
policyName
- The name of the policy document.public String getPolicyDocument()
Constraints:
Length: 1 - 131072
Pattern: [\u0009\u000A\u000D\u0020-\u00FF]+
public void setPolicyDocument(String policyDocument)
Constraints:
Length: 1 - 131072
Pattern: [\u0009\u000A\u000D\u0020-\u00FF]+
policyDocument
- The policy document.public PutGroupPolicyRequest withPolicyDocument(String policyDocument)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 131072
Pattern: [\u0009\u000A\u000D\u0020-\u00FF]+
policyDocument
- The policy document.public String toString()
toString
in class Object
Object.toString()
public PutGroupPolicyRequest clone()
AmazonWebServiceRequest
clone
in class AmazonWebServiceRequest
Object.clone()
Copyright © 2015. All rights reserved.