Class: AWSCDK::IAM::CfnUser::PolicyProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::IAM::CfnUser::PolicyProperty
- Defined in:
- iam/cfn_user.rb
Overview
Contains information about an attached policy.
An attached policy is a managed policy that has been attached to a user, group, or role.
For more information about managed policies, refer to Managed Policies and Inline Policies in the IAM User Guide .
Instance Attribute Summary collapse
-
#policy_document ⇒ Object
readonly
The entire contents of the policy that defines permissions.
-
#policy_name ⇒ String
readonly
The friendly name (not ARN) identifying the policy.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(policy_document:, policy_name:) ⇒ PolicyProperty
constructor
A new instance of PolicyProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(policy_document:, policy_name:) ⇒ PolicyProperty
Returns a new instance of PolicyProperty.
665 666 667 668 669 670 |
# File 'iam/cfn_user.rb', line 665 def initialize(policy_document:, policy_name:) @policy_document = policy_document Jsii::Type.check_type(@policy_document, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJhbnkifQ==")), "policyDocument") @policy_name = policy_name Jsii::Type.check_type(@policy_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "policyName") end |
Instance Attribute Details
#policy_document ⇒ Object (readonly)
The entire contents of the policy that defines permissions.
For more information, see Overview of JSON policies .
678 679 680 |
# File 'iam/cfn_user.rb', line 678 def policy_document @policy_document end |
#policy_name ⇒ String (readonly)
The friendly name (not ARN) identifying the policy.
683 684 685 |
# File 'iam/cfn_user.rb', line 683 def policy_name @policy_name end |
Class Method Details
.jsii_properties ⇒ Object
685 686 687 688 689 690 |
# File 'iam/cfn_user.rb', line 685 def self.jsii_properties { :policy_document => "policyDocument", :policy_name => "policyName", } end |
Instance Method Details
#to_jsii ⇒ Object
692 693 694 695 696 697 698 699 |
# File 'iam/cfn_user.rb', line 692 def to_jsii result = {} result.merge!({ "policyDocument" => @policy_document, "policyName" => @policy_name, }) result.compact end |