Interface PolicyInfo.Builder

  • Method Details

    • type

      The type of policy. Valid values:

      • IDENTITY_BASED_POLICY - An identity-based policy attached to an IAM user, group, or role.

      • PERMISSIONS_BOUNDARY - A permissions boundary for an IAM entity.

      • RESOURCE_BASED_POLICY - A resource-based policy attached to a resource.

      • RESOURCE_CONTROL_POLICY - A resource control policy (RCP) in AWS Organizations.

      • SERVICE_CONTROL_POLICY - A service control policy (SCP) in AWS Organizations.

      • SESSION_POLICY - A session policy passed during role assumption or federation.

      • VPC_ENDPOINT_POLICY - A VPC endpoint policy.

      Parameters:
      type - The type of policy. Valid values:

      • IDENTITY_BASED_POLICY - An identity-based policy attached to an IAM user, group, or role.

      • PERMISSIONS_BOUNDARY - A permissions boundary for an IAM entity.

      • RESOURCE_BASED_POLICY - A resource-based policy attached to a resource.

      • RESOURCE_CONTROL_POLICY - A resource control policy (RCP) in AWS Organizations.

      • SERVICE_CONTROL_POLICY - A service control policy (SCP) in AWS Organizations.

      • SESSION_POLICY - A session policy passed during role assumption or federation.

      • VPC_ENDPOINT_POLICY - A VPC endpoint policy.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • type

      The type of policy. Valid values:

      • IDENTITY_BASED_POLICY - An identity-based policy attached to an IAM user, group, or role.

      • PERMISSIONS_BOUNDARY - A permissions boundary for an IAM entity.

      • RESOURCE_BASED_POLICY - A resource-based policy attached to a resource.

      • RESOURCE_CONTROL_POLICY - A resource control policy (RCP) in AWS Organizations.

      • SERVICE_CONTROL_POLICY - A service control policy (SCP) in AWS Organizations.

      • SESSION_POLICY - A session policy passed during role assumption or federation.

      • VPC_ENDPOINT_POLICY - A VPC endpoint policy.

      Parameters:
      type - The type of policy. Valid values:

      • IDENTITY_BASED_POLICY - An identity-based policy attached to an IAM user, group, or role.

      • PERMISSIONS_BOUNDARY - A permissions boundary for an IAM entity.

      • RESOURCE_BASED_POLICY - A resource-based policy attached to a resource.

      • RESOURCE_CONTROL_POLICY - A resource control policy (RCP) in AWS Organizations.

      • SERVICE_CONTROL_POLICY - A service control policy (SCP) in AWS Organizations.

      • SESSION_POLICY - A session policy passed during role assumption or federation.

      • VPC_ENDPOINT_POLICY - A VPC endpoint policy.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • inline

      PolicyInfo.Builder inline(Boolean inline)

      Specifies whether this is an inline policy (true) or a managed policy (false).

      Parameters:
      inline - Specifies whether this is an inline policy (true) or a managed policy (false ).
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • uri

      A URI that identifies the policy. Use this URI to cross-reference the policy with the matching policies in each evaluation. The value depends on the policy type:

      • For managed policies, this is the policy ARN.

      • For inline policies, which have no ARN, this is an opaque identifier.

      Parameters:
      uri - A URI that identifies the policy. Use this URI to cross-reference the policy with the matching policies in each evaluation. The value depends on the policy type:

      • For managed policies, this is the policy ARN.

      • For inline policies, which have no ARN, this is an opaque identifier.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • attachedTo

      PolicyInfo.Builder attachedTo(Collection<AttachedTo> attachedTo)

      The entities that the policy is attached to. For identity, session, and resource-based policies, this is typically a single entity. For organization control policies (SCPs and RCPs), it can be multiple entities at different levels of the organization hierarchy.

      Parameters:
      attachedTo - The entities that the policy is attached to. For identity, session, and resource-based policies, this is typically a single entity. For organization control policies (SCPs and RCPs), it can be multiple entities at different levels of the organization hierarchy.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • attachedTo

      PolicyInfo.Builder attachedTo(AttachedTo... attachedTo)

      The entities that the policy is attached to. For identity, session, and resource-based policies, this is typically a single entity. For organization control policies (SCPs and RCPs), it can be multiple entities at different levels of the organization hierarchy.

      Parameters:
      attachedTo - The entities that the policy is attached to. For identity, session, and resource-based policies, this is typically a single entity. For organization control policies (SCPs and RCPs), it can be multiple entities at different levels of the organization hierarchy.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • attachedTo

      PolicyInfo.Builder attachedTo(Consumer<AttachedTo.Builder>... attachedTo)

      The entities that the policy is attached to. For identity, session, and resource-based policies, this is typically a single entity. For organization control policies (SCPs and RCPs), it can be multiple entities at different levels of the organization hierarchy.

      This is a convenience method that creates an instance of the AttachedTo.Builder avoiding the need to create one manually via AttachedTo.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to attachedTo(List<AttachedTo>).

      Parameters:
      attachedTo - a consumer that will call methods on AttachedTo.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also: