Class CfnEnvironmentEC2
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.cloud9.CfnEnvironmentEC2
- All Implemented Interfaces:
IInspectable,IEnvironmentEC2Ref,IEnvironmentAware,ITaggable,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.120.0 (build 192dc88)",
date="2025-12-05T22:26:31.582Z")
@Stability(Stable)
public class CfnEnvironmentEC2
extends CfnResource
implements IInspectable, IEnvironmentEC2Ref, ITaggable
The
AWS::Cloud9::EnvironmentEC2 resource creates an Amazon EC2 development environment in AWS Cloud9 .
For more information, see Creating an Environment in the AWS Cloud9 User Guide .
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.cloud9.*;
CfnEnvironmentEC2 cfnEnvironmentEC2 = CfnEnvironmentEC2.Builder.create(this, "MyCfnEnvironmentEC2")
.imageId("imageId")
.instanceType("instanceType")
// the properties below are optional
.automaticStopTimeMinutes(123)
.connectionType("connectionType")
.description("description")
.name("name")
.ownerArn("ownerArn")
.repositories(List.of(RepositoryProperty.builder()
.pathComponent("pathComponent")
.repositoryUrl("repositoryUrl")
.build()))
.subnetId("subnetId")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA fluent builder forCfnEnvironmentEC2.static interfaceTheRepositoryproperty type specifies an AWS CodeCommit source code repository to be cloned into an AWS Cloud9 development environment.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.interfaces.cloud9.IEnvironmentEC2Ref
IEnvironmentEC2Ref.Jsii$Default, IEnvironmentEC2Ref.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggable
ITaggable.Jsii$Default, ITaggable.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnEnvironmentEC2(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnEnvironmentEC2(software.amazon.jsii.JsiiObjectRef objRef) CfnEnvironmentEC2(software.constructs.Construct scope, String id, CfnEnvironmentEC2Props props) Create a newAWS::Cloud9::EnvironmentEC2. -
Method Summary
Modifier and TypeMethodDescriptionstatic StringarnForEnvironmentEC2(IEnvironmentEC2Ref resource) The Amazon Resource Name (ARN) of the development environment, such asarn:aws:cloud9:us-east-2:123456789012:environment:2bc3642873c342e485f7e0c561234567.The name of the environment.The number of minutes until the running instance is shut down after the environment was last used.The connection type used for connecting to an Amazon EC2 environment.The description of the environment to create.A reference to a EnvironmentEC2 resource.The identifier for the Amazon Machine Image (AMI) that's used to create the EC2 instance.The type of instance to connect to the environment (for example,t2.micro).getName()The name of the environment.The Amazon Resource Name (ARN) of the environment owner.Any AWS CodeCommit source code repositories to be cloned into the development environment.The ID of the subnet in Amazon Virtual Private Cloud (Amazon VPC) that AWS Cloud9 will use to communicate with the Amazon Elastic Compute Cloud (Amazon EC2) instance.getTags()Tag Manager which manages the tags for this resource.An array of key-value pairs that will be associated with the new AWS Cloud9 development environment.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.static BooleanChecks whether the given object is a CfnEnvironmentEC2.renderProperties(Map<String, Object> props) voidThe number of minutes until the running instance is shut down after the environment was last used.voidsetConnectionType(String value) The connection type used for connecting to an Amazon EC2 environment.voidsetDescription(String value) The description of the environment to create.voidsetImageId(String value) The identifier for the Amazon Machine Image (AMI) that's used to create the EC2 instance.voidsetInstanceType(String value) The type of instance to connect to the environment (for example,t2.micro).voidThe name of the environment.voidsetOwnerArn(String value) The Amazon Resource Name (ARN) of the environment owner.voidsetRepositories(List<Object> value) Any AWS CodeCommit source code repositories to be cloned into the development environment.voidsetRepositories(IResolvable value) Any AWS CodeCommit source code repositories to be cloned into the development environment.voidsetSubnetId(String value) The ID of the subnet in Amazon Virtual Private Cloud (Amazon VPC) that AWS Cloud9 will use to communicate with the Amazon Elastic Compute Cloud (Amazon EC2) instance.voidsetTagsRaw(List<CfnTag> value) An array of key-value pairs that will be associated with the new AWS Cloud9 development environment.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getEnv, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.interfaces.IEnvironmentAware
getEnvMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnEnvironmentEC2
protected CfnEnvironmentEC2(software.amazon.jsii.JsiiObjectRef objRef) -
CfnEnvironmentEC2
protected CfnEnvironmentEC2(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnEnvironmentEC2
@Stability(Stable) public CfnEnvironmentEC2(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnEnvironmentEC2Props props) Create a newAWS::Cloud9::EnvironmentEC2.- Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
arnForEnvironmentEC2
@Stability(Stable) @NotNull public static String arnForEnvironmentEC2(@NotNull IEnvironmentEC2Ref resource) - Parameters:
resource- This parameter is required.
-
isCfnEnvironmentEC2
Checks whether the given object is a CfnEnvironmentEC2.- Parameters:
x- This parameter is required.
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrArn
The Amazon Resource Name (ARN) of the development environment, such asarn:aws:cloud9:us-east-2:123456789012:environment:2bc3642873c342e485f7e0c561234567. -
getAttrId
-
getAttrName
The name of the environment. -
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getEnvironmentEc2Ref
A reference to a EnvironmentEC2 resource.- Specified by:
getEnvironmentEc2Refin interfaceIEnvironmentEC2Ref
-
getTags
Tag Manager which manages the tags for this resource. -
getImageId
The identifier for the Amazon Machine Image (AMI) that's used to create the EC2 instance. -
setImageId
The identifier for the Amazon Machine Image (AMI) that's used to create the EC2 instance. -
getInstanceType
The type of instance to connect to the environment (for example,t2.micro). -
setInstanceType
The type of instance to connect to the environment (for example,t2.micro). -
getAutomaticStopTimeMinutes
The number of minutes until the running instance is shut down after the environment was last used. -
setAutomaticStopTimeMinutes
The number of minutes until the running instance is shut down after the environment was last used. -
getConnectionType
The connection type used for connecting to an Amazon EC2 environment. -
setConnectionType
The connection type used for connecting to an Amazon EC2 environment. -
getDescription
The description of the environment to create. -
setDescription
The description of the environment to create. -
getName
The name of the environment. -
setName
The name of the environment. -
getOwnerArn
The Amazon Resource Name (ARN) of the environment owner. -
setOwnerArn
The Amazon Resource Name (ARN) of the environment owner. -
getRepositories
Any AWS CodeCommit source code repositories to be cloned into the development environment.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnEnvironmentEC2.RepositoryProperty> -
setRepositories
Any AWS CodeCommit source code repositories to be cloned into the development environment. -
setRepositories
Any AWS CodeCommit source code repositories to be cloned into the development environment. -
getSubnetId
The ID of the subnet in Amazon Virtual Private Cloud (Amazon VPC) that AWS Cloud9 will use to communicate with the Amazon Elastic Compute Cloud (Amazon EC2) instance. -
setSubnetId
The ID of the subnet in Amazon Virtual Private Cloud (Amazon VPC) that AWS Cloud9 will use to communicate with the Amazon Elastic Compute Cloud (Amazon EC2) instance. -
getTagsRaw
An array of key-value pairs that will be associated with the new AWS Cloud9 development environment. -
setTagsRaw
An array of key-value pairs that will be associated with the new AWS Cloud9 development environment.
-