public class TestAuthorizationRequest extends AmazonWebServiceRequest implements java.io.Serializable
Tests if a specified principal is authorized to perform an AWS IoT action on a specified resource. Use this to test and debug the authorization behavior of devices that connect to the AWS IoT device gateway.
Constructor and Description |
---|
TestAuthorizationRequest() |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
java.util.List<AuthInfo> |
getAuthInfos()
A list of authorization info objects.
|
java.lang.String |
getClientId()
The MQTT client ID.
|
java.lang.String |
getCognitoIdentityPoolId()
The Cognito identity pool ID.
|
java.util.List<java.lang.String> |
getPolicyNamesToAdd()
When testing custom authorization, the policies specified here are
treated as if they are attached to the principal being authorized.
|
java.util.List<java.lang.String> |
getPolicyNamesToSkip()
When testing custom authorization, the policies specified here are
treated as if they are not attached to the principal being authorized.
|
java.lang.String |
getPrincipal()
The principal.
|
int |
hashCode() |
void |
setAuthInfos(java.util.Collection<AuthInfo> authInfos)
A list of authorization info objects.
|
void |
setClientId(java.lang.String clientId)
The MQTT client ID.
|
void |
setCognitoIdentityPoolId(java.lang.String cognitoIdentityPoolId)
The Cognito identity pool ID.
|
void |
setPolicyNamesToAdd(java.util.Collection<java.lang.String> policyNamesToAdd)
When testing custom authorization, the policies specified here are
treated as if they are attached to the principal being authorized.
|
void |
setPolicyNamesToSkip(java.util.Collection<java.lang.String> policyNamesToSkip)
When testing custom authorization, the policies specified here are
treated as if they are not attached to the principal being authorized.
|
void |
setPrincipal(java.lang.String principal)
The principal.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
TestAuthorizationRequest |
withAuthInfos(AuthInfo... authInfos)
A list of authorization info objects.
|
TestAuthorizationRequest |
withAuthInfos(java.util.Collection<AuthInfo> authInfos)
A list of authorization info objects.
|
TestAuthorizationRequest |
withClientId(java.lang.String clientId)
The MQTT client ID.
|
TestAuthorizationRequest |
withCognitoIdentityPoolId(java.lang.String cognitoIdentityPoolId)
The Cognito identity pool ID.
|
TestAuthorizationRequest |
withPolicyNamesToAdd(java.util.Collection<java.lang.String> policyNamesToAdd)
When testing custom authorization, the policies specified here are
treated as if they are attached to the principal being authorized.
|
TestAuthorizationRequest |
withPolicyNamesToAdd(java.lang.String... policyNamesToAdd)
When testing custom authorization, the policies specified here are
treated as if they are attached to the principal being authorized.
|
TestAuthorizationRequest |
withPolicyNamesToSkip(java.util.Collection<java.lang.String> policyNamesToSkip)
When testing custom authorization, the policies specified here are
treated as if they are not attached to the principal being authorized.
|
TestAuthorizationRequest |
withPolicyNamesToSkip(java.lang.String... policyNamesToSkip)
When testing custom authorization, the policies specified here are
treated as if they are not attached to the principal being authorized.
|
TestAuthorizationRequest |
withPrincipal(java.lang.String principal)
The principal.
|
clone, getCloneRoot, getCloneSource, getGeneralProgressListener, getRequestClientOptions, getRequestCredentials, getRequestMetricCollector, setGeneralProgressListener, setRequestCredentials, setRequestMetricCollector, withGeneralProgressListener, withRequestMetricCollector
public java.lang.String getPrincipal()
The principal. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).
The principal. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup /groupName) and CognitoId (region:id).
public void setPrincipal(java.lang.String principal)
The principal. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).
principal
- The principal. Valid principals are CertificateArn (arn:aws:iot :region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup /groupName) and CognitoId (region:id).
public TestAuthorizationRequest withPrincipal(java.lang.String principal)
The principal. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).
Returns a reference to this object so that method calls can be chained together.
principal
- The principal. Valid principals are CertificateArn (arn:aws:iot :region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup /groupName) and CognitoId (region:id).
public java.lang.String getCognitoIdentityPoolId()
The Cognito identity pool ID.
The Cognito identity pool ID.
public void setCognitoIdentityPoolId(java.lang.String cognitoIdentityPoolId)
The Cognito identity pool ID.
cognitoIdentityPoolId
- The Cognito identity pool ID.
public TestAuthorizationRequest withCognitoIdentityPoolId(java.lang.String cognitoIdentityPoolId)
The Cognito identity pool ID.
Returns a reference to this object so that method calls can be chained together.
cognitoIdentityPoolId
- The Cognito identity pool ID.
public java.util.List<AuthInfo> getAuthInfos()
A list of authorization info objects. Simulating authorization will
create a response for each authInfo
object in the list.
A list of authorization info objects. Simulating authorization
will create a response for each authInfo
object in
the list.
public void setAuthInfos(java.util.Collection<AuthInfo> authInfos)
A list of authorization info objects. Simulating authorization will
create a response for each authInfo
object in the list.
authInfos
-
A list of authorization info objects. Simulating authorization
will create a response for each authInfo
object
in the list.
public TestAuthorizationRequest withAuthInfos(AuthInfo... authInfos)
A list of authorization info objects. Simulating authorization will
create a response for each authInfo
object in the list.
Returns a reference to this object so that method calls can be chained together.
authInfos
-
A list of authorization info objects. Simulating authorization
will create a response for each authInfo
object
in the list.
public TestAuthorizationRequest withAuthInfos(java.util.Collection<AuthInfo> authInfos)
A list of authorization info objects. Simulating authorization will
create a response for each authInfo
object in the list.
Returns a reference to this object so that method calls can be chained together.
authInfos
-
A list of authorization info objects. Simulating authorization
will create a response for each authInfo
object
in the list.
public java.lang.String getClientId()
The MQTT client ID.
The MQTT client ID.
public void setClientId(java.lang.String clientId)
The MQTT client ID.
clientId
- The MQTT client ID.
public TestAuthorizationRequest withClientId(java.lang.String clientId)
The MQTT client ID.
Returns a reference to this object so that method calls can be chained together.
clientId
- The MQTT client ID.
public java.util.List<java.lang.String> getPolicyNamesToAdd()
When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
public void setPolicyNamesToAdd(java.util.Collection<java.lang.String> policyNamesToAdd)
When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
policyNamesToAdd
- When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
public TestAuthorizationRequest withPolicyNamesToAdd(java.lang.String... policyNamesToAdd)
When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
Returns a reference to this object so that method calls can be chained together.
policyNamesToAdd
- When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
public TestAuthorizationRequest withPolicyNamesToAdd(java.util.Collection<java.lang.String> policyNamesToAdd)
When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
Returns a reference to this object so that method calls can be chained together.
policyNamesToAdd
- When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
public java.util.List<java.lang.String> getPolicyNamesToSkip()
When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
public void setPolicyNamesToSkip(java.util.Collection<java.lang.String> policyNamesToSkip)
When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
policyNamesToSkip
- When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
public TestAuthorizationRequest withPolicyNamesToSkip(java.lang.String... policyNamesToSkip)
When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
Returns a reference to this object so that method calls can be chained together.
policyNamesToSkip
- When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
public TestAuthorizationRequest withPolicyNamesToSkip(java.util.Collection<java.lang.String> policyNamesToSkip)
When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
Returns a reference to this object so that method calls can be chained together.
policyNamesToSkip
- When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
Copyright © 2018 Amazon Web Services, Inc. All Rights Reserved.