Class CfnFunctionProps
Properties for defining a CfnFunction.
Implements
Inherited Members
Namespace: Amazon.CDK.AWS.CloudFront
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnFunctionProps : ICfnFunctionProps
Syntax (vb)
Public Class CfnFunctionProps Implements ICfnFunctionProps
Remarks
See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-cloudfront-function.html
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.CloudFront;
var cfnFunctionProps = new CfnFunctionProps {
FunctionCode = "functionCode",
FunctionConfig = new FunctionConfigProperty {
Comment = "comment",
Runtime = "runtime",
// the properties below are optional
KeyValueStoreAssociations = new [] { new KeyValueStoreAssociationProperty {
KeyValueStoreArn = "keyValueStoreArn"
} }
},
Name = "name",
// the properties below are optional
AutoPublish = false,
FunctionMetadata = new FunctionMetadataProperty {
FunctionArn = "functionArn"
}
};
Synopsis
Constructors
| CfnFunctionProps() | Properties for defining a |
Properties
| AutoPublish | A flag that determines whether to automatically publish the function to the |
| FunctionCode | The function code. |
| FunctionConfig | Contains configuration information about a CloudFront function. |
| FunctionMetadata | Contains metadata about a CloudFront function. |
| Name | A name to identify the function. |
Constructors
CfnFunctionProps()
Properties for defining a CfnFunction.
public CfnFunctionProps()
Remarks
See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-cloudfront-function.html
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.CloudFront;
var cfnFunctionProps = new CfnFunctionProps {
FunctionCode = "functionCode",
FunctionConfig = new FunctionConfigProperty {
Comment = "comment",
Runtime = "runtime",
// the properties below are optional
KeyValueStoreAssociations = new [] { new KeyValueStoreAssociationProperty {
KeyValueStoreArn = "keyValueStoreArn"
} }
},
Name = "name",
// the properties below are optional
AutoPublish = false,
FunctionMetadata = new FunctionMetadataProperty {
FunctionArn = "functionArn"
}
};
Properties
AutoPublish
A flag that determines whether to automatically publish the function to the LIVE stage when it’s created.
public object? AutoPublish { get; set; }
Property Value
Remarks
To automatically publish to the LIVE stage, set this property to true .
Type union: either bool or IResolvable
FunctionCode
The function code.
public string FunctionCode { get; set; }
Property Value
Remarks
For more information about writing a CloudFront function, see Writing function code for CloudFront Functions in the Amazon CloudFront Developer Guide .
FunctionConfig
Contains configuration information about a CloudFront function.
public object FunctionConfig { get; set; }
Property Value
Remarks
FunctionMetadata
Contains metadata about a CloudFront function.
public object? FunctionMetadata { get; set; }
Property Value
Remarks
Name
A name to identify the function.
public string Name { get; set; }