Show / Hide Table of Contents

Interface IAddToResourcePolicyResult

Result of calling addToResourcePolicy.

Namespace: Amazon.CDK.AWS.IAM
Assembly: Amazon.CDK.AWS.IAM.dll
Syntax (csharp)
public interface IAddToResourcePolicyResult
Syntax (vb)
Public Interface IAddToResourcePolicyResult
Remarks

ExampleMetadata: infused

Examples
IBucket bucket = Bucket.FromBucketName(this, "existingBucket", "bucket-name");

// No policy statement will be added to the resource
AddToResourcePolicyResult result = bucket.AddToResourcePolicy(new PolicyStatement(new PolicyStatementProps {
    Actions = new [] { "s3:GetObject" },
    Resources = new [] { bucket.ArnForObjects("file.txt") },
    Principals = new [] { new AccountRootPrincipal() }
}));

Synopsis

Properties

PolicyDependable

Dependable which allows depending on the policy change being applied.

StatementAdded

Whether the statement was added.

Properties

PolicyDependable

Dependable which allows depending on the policy change being applied.

virtual IDependable PolicyDependable { get; }
Property Value

IDependable

Remarks

Default: - If statementAdded is true, the resource object itself. Otherwise, no dependable.

StatementAdded

Whether the statement was added.

bool StatementAdded { get; }
Property Value

System.Boolean

Back to top Generated by DocFX