Table of Contents

Interface IResourceEnvironment

Namespace
Amazon.CDK
Assembly
Amazon.CDK.dll

Represents the environment a given resource lives in.

public interface IResourceEnvironment

Examples

// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK;
             var resourceEnvironment = new ResourceEnvironment {
                 Account = "account",
                 Region = "region"
             };

Remarks

Used as the return value for the {@link IResource.env} property.

ExampleMetadata: fixture=_generated

Properties

Account

The AWS account ID that this resource belongs to.

string Account { get; }

Property Value

string

Remarks

Since this can be a Token (for example, when the account is CloudFormation's AWS::AccountId intrinsic), make sure to use Token.compareStrings() instead of just comparing the values for equality.

Region

The AWS region that this resource belongs to.

string Region { get; }

Property Value

string

Remarks

Since this can be a Token (for example, when the region is CloudFormation's AWS::Region intrinsic), make sure to use Token.compareStrings() instead of just comparing the values for equality.