Skip to content
v2.278.0

CfnTemplateProps Struct ​

Properties for defining a CfnTemplate.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_networksecuritymanager as networksecuritymanager } from 'aws-cdk-lib';
const cfnTemplateProps: networksecuritymanager.CfnTemplateProps = {
  templateName: 'templateName',

  // the properties below are optional
  associatedRuleList: [{
    ruleArn: 'ruleArn',
  }],
  firewallType: 'firewallType',
  tags: [{
    key: 'key',
    value: 'value',
  }],
  templateDescription: 'templateDescription',
};
python
from aws_cdk import CfnTag
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_networksecuritymanager as networksecuritymanager

cfn_template_props = networksecuritymanager.CfnTemplateProps(
    template_name="templateName",

    # the properties below are optional
    associated_rule_list=[networksecuritymanager.CfnTemplate.AssociatedRuleProperty(
        rule_arn="ruleArn"
    )],
    firewall_type="firewallType",
    tags=[CfnTag(
        key="key",
        value="value"
    )],
    template_description="templateDescription"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.networksecuritymanager.*;

CfnTemplateProps cfnTemplateProps = CfnTemplateProps.builder()
        .templateName("templateName")

        // the properties below are optional
        .associatedRuleList(List.of(AssociatedRuleProperty.builder()
                .ruleArn("ruleArn")
                .build()))
        .firewallType("firewallType")
        .tags(List.of(CfnTag.builder()
                .key("key")
                .value("value")
                .build()))
        .templateDescription("templateDescription")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.NetworkSecurityManager;

var cfnTemplateProps = new CfnTemplateProps {
    TemplateName = "templateName",

    // the properties below are optional
    AssociatedRuleList = new [] { new AssociatedRuleProperty {
        RuleArn = "ruleArn"
    } },
    FirewallType = "firewallType",
    Tags = new [] { new CfnTag {
        Key = "key",
        Value = "value"
    } },
    TemplateDescription = "templateDescription"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

cfnTemplateProps := &CfnTemplateProps{
	TemplateName: jsii.String("templateName"),

	// the properties below are optional
	AssociatedRuleList: []interface{}{
		&AssociatedRuleProperty{
			RuleArn: jsii.String("ruleArn"),
		},
	},
	FirewallType: jsii.String("firewallType"),
	Tags: []CfnTag{
		&CfnTag{
			Key: jsii.String("key"),
			Value: jsii.String("value"),
		},
	},
	TemplateDescription: jsii.String("templateDescription"),
}

Properties ​

associatedRuleListoptionalIResolvable | IResolvable | CfnTemplate.AssociatedRuleProperty[]associated_rule_listoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, AssociatedRuleProperty]]]associatedRuleListoptionalIResolvableAssociatedRuleListoptionalIResolvableAssociatedRuleListoptionalinterface{} #
List of rules associated with this template.
firewallTypeoptionalstringfirewall_typeoptionalstrfirewallTypeoptionalStringFirewallTypeoptionalstringFirewallTypeoptional*string #
The type of firewall.
tagsoptionalCfnTag[]tagsoptionaltyping.List[CfnTag]tagsoptionalList<CfnTag>TagsoptionalCfnTag[]Tagsoptional*[]CfnTag #
The tags associated with the template.
templateDescriptionoptionalstringtemplate_descriptionoptionalstrtemplateDescriptionoptionalStringTemplateDescriptionoptionalstringTemplateDescriptionoptional*string #
A description of the template.
templateNamestringtemplate_namestrtemplateNameStringTemplateNamestringTemplateName*string required #
The name of the template.