Interface CreateResourcePolicyStatementRequest.Builder
- All Superinterfaces:
AwsRequest.Builder
,Buildable
,CopyableBuilder<CreateResourcePolicyStatementRequest.Builder,
,CreateResourcePolicyStatementRequest> LexModelsV2Request.Builder
,SdkBuilder<CreateResourcePolicyStatementRequest.Builder,
,CreateResourcePolicyStatementRequest> SdkPojo
,SdkRequest.Builder
- Enclosing class:
CreateResourcePolicyStatementRequest
-
Method Summary
Modifier and TypeMethodDescriptionThe Amazon Lex action that this policy either allows or denies.action
(Collection<String> action) The Amazon Lex action that this policy either allows or denies.Specifies a condition when the policy is in effect.Determines whether the statement allows or denies access to the resource.Determines whether the statement allows or denies access to the resource.expectedRevisionId
(String expectedRevisionId) The identifier of the revision of the policy to edit.overrideConfiguration
(Consumer<AwsRequestOverrideConfiguration.Builder> builderConsumer) Add an optional request override configuration.overrideConfiguration
(AwsRequestOverrideConfiguration overrideConfiguration) Add an optional request override configuration.principal
(Collection<Principal> principal) An IAM principal, such as an IAM user, IAM role, or Amazon Web Services services that is allowed or denied access to a resource.principal
(Consumer<Principal.Builder>... principal) An IAM principal, such as an IAM user, IAM role, or Amazon Web Services services that is allowed or denied access to a resource.An IAM principal, such as an IAM user, IAM role, or Amazon Web Services services that is allowed or denied access to a resource.resourceArn
(String resourceArn) The Amazon Resource Name (ARN) of the bot or bot alias that the resource policy is attached to.statementId
(String statementId) The name of the statement.Methods inherited from interface software.amazon.awssdk.awscore.AwsRequest.Builder
overrideConfiguration
Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
Methods inherited from interface software.amazon.awssdk.services.lexmodelsv2.model.LexModelsV2Request.Builder
build
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFieldNameToField, sdkFields
-
Method Details
-
resourceArn
The Amazon Resource Name (ARN) of the bot or bot alias that the resource policy is attached to.
- Parameters:
resourceArn
- The Amazon Resource Name (ARN) of the bot or bot alias that the resource policy is attached to.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
statementId
The name of the statement. The ID is the same as the
Sid
IAM property. The statement name must be unique within the policy. For more information, see IAM JSON policy elements: Sid.- Parameters:
statementId
- The name of the statement. The ID is the same as theSid
IAM property. The statement name must be unique within the policy. For more information, see IAM JSON policy elements: Sid.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
effect
Determines whether the statement allows or denies access to the resource.
- Parameters:
effect
- Determines whether the statement allows or denies access to the resource.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
effect
Determines whether the statement allows or denies access to the resource.
- Parameters:
effect
- Determines whether the statement allows or denies access to the resource.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
principal
An IAM principal, such as an IAM user, IAM role, or Amazon Web Services services that is allowed or denied access to a resource. For more information, see Amazon Web Services JSON policy elements: Principal.
- Parameters:
principal
- An IAM principal, such as an IAM user, IAM role, or Amazon Web Services services that is allowed or denied access to a resource. For more information, see Amazon Web Services JSON policy elements: Principal.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
principal
An IAM principal, such as an IAM user, IAM role, or Amazon Web Services services that is allowed or denied access to a resource. For more information, see Amazon Web Services JSON policy elements: Principal.
- Parameters:
principal
- An IAM principal, such as an IAM user, IAM role, or Amazon Web Services services that is allowed or denied access to a resource. For more information, see Amazon Web Services JSON policy elements: Principal.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
principal
An IAM principal, such as an IAM user, IAM role, or Amazon Web Services services that is allowed or denied access to a resource. For more information, see Amazon Web Services JSON policy elements: Principal.
This is a convenience method that creates an instance of thePrincipal.Builder
avoiding the need to create one manually viaPrincipal.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed toprincipal(List<Principal>)
.- Parameters:
principal
- a consumer that will call methods onPrincipal.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
action
The Amazon Lex action that this policy either allows or denies. The action must apply to the resource type of the specified ARN. For more information, see Actions, resources, and condition keys for Amazon Lex V2.
- Parameters:
action
- The Amazon Lex action that this policy either allows or denies. The action must apply to the resource type of the specified ARN. For more information, see Actions, resources, and condition keys for Amazon Lex V2.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
action
The Amazon Lex action that this policy either allows or denies. The action must apply to the resource type of the specified ARN. For more information, see Actions, resources, and condition keys for Amazon Lex V2.
- Parameters:
action
- The Amazon Lex action that this policy either allows or denies. The action must apply to the resource type of the specified ARN. For more information, see Actions, resources, and condition keys for Amazon Lex V2.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
condition
CreateResourcePolicyStatementRequest.Builder condition(Map<String, ? extends Map<String, String>> condition) Specifies a condition when the policy is in effect. If the principal of the policy is a service principal, you must provide two condition blocks, one with a SourceAccount global condition key and one with a SourceArn global condition key.
For more information, see IAM JSON policy elements: Condition .
- Parameters:
condition
- Specifies a condition when the policy is in effect. If the principal of the policy is a service principal, you must provide two condition blocks, one with a SourceAccount global condition key and one with a SourceArn global condition key.For more information, see IAM JSON policy elements: Condition .
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
expectedRevisionId
The identifier of the revision of the policy to edit. If this revision ID doesn't match the current revision ID, Amazon Lex throws an exception.
If you don't specify a revision, Amazon Lex overwrites the contents of the policy with the new values.
- Parameters:
expectedRevisionId
- The identifier of the revision of the policy to edit. If this revision ID doesn't match the current revision ID, Amazon Lex throws an exception.If you don't specify a revision, Amazon Lex overwrites the contents of the policy with the new values.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
overrideConfiguration
CreateResourcePolicyStatementRequest.Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration) Description copied from interface:AwsRequest.Builder
Add an optional request override configuration.- Specified by:
overrideConfiguration
in interfaceAwsRequest.Builder
- Parameters:
overrideConfiguration
- The override configuration.- Returns:
- This object for method chaining.
-
overrideConfiguration
CreateResourcePolicyStatementRequest.Builder overrideConfiguration(Consumer<AwsRequestOverrideConfiguration.Builder> builderConsumer) Description copied from interface:AwsRequest.Builder
Add an optional request override configuration.- Specified by:
overrideConfiguration
in interfaceAwsRequest.Builder
- Parameters:
builderConsumer
- AConsumer
to which an emptyAwsRequestOverrideConfiguration.Builder
will be given.- Returns:
- This object for method chaining.
-