public class CreatePolicyRequest extends AmazonWebServiceRequest implements Serializable
Creates an AWS IoT policy.
The created policy is the default version for the policy. This operation creates a policy version with a version identifier of 1 and sets 1 as the policy's default version.
| Constructor and Description |
|---|
CreatePolicyRequest() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
String |
getPolicyDocument()
The JSON document that describes the policy.
|
String |
getPolicyName()
The policy name.
|
int |
hashCode() |
void |
setPolicyDocument(String policyDocument)
The JSON document that describes the policy.
|
void |
setPolicyName(String policyName)
The policy name.
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
CreatePolicyRequest |
withPolicyDocument(String policyDocument)
The JSON document that describes the policy.
|
CreatePolicyRequest |
withPolicyName(String policyName)
The policy name.
|
clone, copyBaseTo, getCloneRoot, getCloneSource, getGeneralProgressListener, getRequestClientOptions, getRequestCredentials, getRequestMetricCollector, setGeneralProgressListener, setRequestCredentials, setRequestMetricCollector, withGeneralProgressListener, withRequestMetricCollectorpublic String getPolicyName()
The policy name.
Constraints:
Length: 1 - 128
Pattern: [\w+=,.@-]+
The policy name.
public void setPolicyName(String policyName)
The policy name.
Constraints:
Length: 1 - 128
Pattern: [\w+=,.@-]+
policyName - The policy name.
public CreatePolicyRequest withPolicyName(String policyName)
The policy name.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 128
Pattern: [\w+=,.@-]+
policyName - The policy name.
public String getPolicyDocument()
The JSON document that describes the policy. policyDocument must have a minimum length of 1, with a maximum length of 2048, excluding whitespace.
The JSON document that describes the policy. policyDocument must have a minimum length of 1, with a maximum length of 2048, excluding whitespace.
public void setPolicyDocument(String policyDocument)
The JSON document that describes the policy. policyDocument must have a minimum length of 1, with a maximum length of 2048, excluding whitespace.
policyDocument - The JSON document that describes the policy. policyDocument must have a minimum length of 1, with a maximum length of 2048, excluding whitespace.
public CreatePolicyRequest withPolicyDocument(String policyDocument)
The JSON document that describes the policy. policyDocument must have a minimum length of 1, with a maximum length of 2048, excluding whitespace.
Returns a reference to this object so that method calls can be chained together.
policyDocument - The JSON document that describes the policy. policyDocument must have a minimum length of 1, with a maximum length of 2048, excluding whitespace.
public String toString()
toString in class ObjectObject.toString()Copyright © 2017. All rights reserved.