public static final class AttachPolicyRequest.Builder extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
AttachPolicyRequest |
build() |
AttachPolicyRequest.Builder |
policyName(String policyName)
The name of the policy.
|
AttachPolicyRequest.Builder |
policyType(String policyType)
The type of the policy.
|
AttachPolicyRequest.Builder |
principalName(String principalName)
The name of the object to which you want to attach the policy.
|
AttachPolicyRequest.Builder |
principalType(String principalType)
The type of the object to which you want to attach the policy.
|
AttachPolicyRequest.Builder |
resourceGroupId(String resourceGroupId)
The effective scope of the policy.
|
public AttachPolicyRequest.Builder policyName(String policyName)
The name must be 1 to 128 characters in length and can contain letters, digits, and hyphens (-).
public AttachPolicyRequest.Builder policyType(String policyType)
* Custom: custom policy * System: system policy
public AttachPolicyRequest.Builder principalName(String principalName)
* If you want to attach the policy to a RAM user, specify the name in the \
public AttachPolicyRequest.Builder principalType(String principalType)
* IMSUser: RAM user * IMSGroup: RAM user group * ServiceRole: RAM role
public AttachPolicyRequest.Builder resourceGroupId(String resourceGroupId)
* ID of a resource group: indicates that the policy takes effect for the resources in the resource group. * ID of the Alibaba Cloud account to which the authorized object belongs: indicates that the policy takes effect for the resources within the Alibaba Cloud account.
public AttachPolicyRequest build()
Copyright © 2023. All rights reserved.