Interface UpdatePolicyRequest.Builder
- All Superinterfaces:
AwsRequest.Builder,Buildable,CopyableBuilder<UpdatePolicyRequest.Builder,,UpdatePolicyRequest> SdkBuilder<UpdatePolicyRequest.Builder,,UpdatePolicyRequest> SdkPojo,SdkRequest.Builder,VerifiedPermissionsRequest.Builder
- Enclosing class:
UpdatePolicyRequest
-
Method Summary
Modifier and TypeMethodDescriptiondefault UpdatePolicyRequest.Builderdefinition(Consumer<UpdatePolicyDefinition.Builder> definition) Specifies the updated policy content that you want to replace on the specified policy.definition(UpdatePolicyDefinition definition) Specifies the updated policy content that you want to replace on the specified policy.Specifies a name for the policy that is unique among all policies within the policy store.overrideConfiguration(Consumer<AwsRequestOverrideConfiguration.Builder> builderConsumer) Add an optional request override configuration.overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration) Add an optional request override configuration.Specifies the ID of the policy that you want to update.policyStoreId(String policyStoreId) Specifies the ID of the policy store that contains the policy that you want to update.Methods inherited from interface software.amazon.awssdk.awscore.AwsRequest.Builder
overrideConfigurationMethods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copyMethods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, buildMethods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFieldNameToField, sdkFieldsMethods inherited from interface software.amazon.awssdk.services.verifiedpermissions.model.VerifiedPermissionsRequest.Builder
build
-
Method Details
-
policyStoreId
Specifies the ID of the policy store that contains the policy that you want to update.
To specify a policy store, use its ID or alias name. When using an alias name, prefix it with
policy-store-alias/. For example:-
ID:
PSEXAMPLEabcdefg111111 -
Alias name:
policy-store-alias/example-policy-store
To view aliases, use ListPolicyStoreAliases.
- Parameters:
policyStoreId- Specifies the ID of the policy store that contains the policy that you want to update.To specify a policy store, use its ID or alias name. When using an alias name, prefix it with
policy-store-alias/. For example:-
ID:
PSEXAMPLEabcdefg111111 -
Alias name:
policy-store-alias/example-policy-store
To view aliases, use ListPolicyStoreAliases.
-
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
-
policyId
Specifies the ID of the policy that you want to update. To find this value, you can use ListPolicies.
You can use the policy name in place of the policy ID. When using a name, prefix it with
name/. For example:-
ID:
SPEXAMPLEabcdefg111111 -
Name:
name/example-policy
- Parameters:
policyId- Specifies the ID of the policy that you want to update. To find this value, you can use ListPolicies.You can use the policy name in place of the policy ID. When using a name, prefix it with
name/. For example:-
ID:
SPEXAMPLEabcdefg111111 -
Name:
name/example-policy
-
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
-
definition
Specifies the updated policy content that you want to replace on the specified policy. The content must be valid Cedar policy language text.
If you don't specify this parameter, the existing policy definition remains unchanged.
You can change only the following elements from the policy definition:
-
The
actionreferenced by the policy. -
Any conditional clauses, such as
whenorunlessclauses.
You can't change the following elements:
-
Changing from
statictotemplateLinked. -
Changing the effect of the policy from
permitorforbid. -
The
principalreferenced by the policy. -
The
resourcereferenced by the policy.
- Parameters:
definition- Specifies the updated policy content that you want to replace on the specified policy. The content must be valid Cedar policy language text.If you don't specify this parameter, the existing policy definition remains unchanged.
You can change only the following elements from the policy definition:
-
The
actionreferenced by the policy. -
Any conditional clauses, such as
whenorunlessclauses.
You can't change the following elements:
-
Changing from
statictotemplateLinked. -
Changing the effect of the policy from
permitorforbid. -
The
principalreferenced by the policy. -
The
resourcereferenced by the policy.
-
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
-
definition
Specifies the updated policy content that you want to replace on the specified policy. The content must be valid Cedar policy language text.
If you don't specify this parameter, the existing policy definition remains unchanged.
You can change only the following elements from the policy definition:
-
The
actionreferenced by the policy. -
Any conditional clauses, such as
whenorunlessclauses.
You can't change the following elements:
-
Changing from
statictotemplateLinked. -
Changing the effect of the policy from
permitorforbid. -
The
principalreferenced by the policy. -
The
resourcereferenced by the policy.
UpdatePolicyDefinition.Builderavoiding the need to create one manually viaUpdatePolicyDefinition.builder().When the
Consumercompletes,SdkBuilder.build()is called immediately and its result is passed todefinition(UpdatePolicyDefinition).- Parameters:
definition- a consumer that will call methods onUpdatePolicyDefinition.Builder- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
-
name
Specifies a name for the policy that is unique among all policies within the policy store. You can use the name in place of the policy ID in API operations that reference the policy. The name must be prefixed with
name/.If you don't include the name in an update request, the existing name is unchanged. To remove a name, set it to an empty string (
"").If you specify a name that is already associated with another policy in the policy store, you receive a
ConflictExceptionerror.- Parameters:
name- Specifies a name for the policy that is unique among all policies within the policy store. You can use the name in place of the policy ID in API operations that reference the policy. The name must be prefixed withname/.If you don't include the name in an update request, the existing name is unchanged. To remove a name, set it to an empty string (
"").If you specify a name that is already associated with another policy in the policy store, you receive a
ConflictExceptionerror.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
overrideConfiguration
UpdatePolicyRequest.Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration) Description copied from interface:AwsRequest.BuilderAdd an optional request override configuration.- Specified by:
overrideConfigurationin interfaceAwsRequest.Builder- Parameters:
overrideConfiguration- The override configuration.- Returns:
- This object for method chaining.
-
overrideConfiguration
UpdatePolicyRequest.Builder overrideConfiguration(Consumer<AwsRequestOverrideConfiguration.Builder> builderConsumer) Description copied from interface:AwsRequest.BuilderAdd an optional request override configuration.- Specified by:
overrideConfigurationin interfaceAwsRequest.Builder- Parameters:
builderConsumer- AConsumerto which an emptyAwsRequestOverrideConfiguration.Builderwill be given.- Returns:
- This object for method chaining.
-