Class CfnFunction

java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
All Implemented Interfaces:
IInspectable, IEnvironmentAware, IFunctionRef, ITaggableV2, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.139.0 (build 26a6b54)", date="2026-09-02T11:03:14.089Z") @Stability(Stable) public class CfnFunction extends CfnResource implements IInspectable, IFunctionRef, ITaggableV2
Resource Type definition for AWS::MediaTailor::Function.

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.mediatailor.*;
 CfnFunction cfnFunction = CfnFunction.Builder.create(this, "MyCfnFunction")
         .functionId("functionId")
         .functionType("functionType")
         // the properties below are optional
         .customOutputConfiguration(CustomOutputConfigurationProperty.builder()
                 .runtime("runtime")
                 // the properties below are optional
                 .output(Map.of(
                         "outputKey", "output"))
                 .build())
         .description("description")
         .httpRequestConfiguration(HttpRequestConfigurationProperty.builder()
                 .methodType("methodType")
                 .requestTimeoutMilliseconds(123)
                 .runtime("runtime")
                 .url("url")
                 // the properties below are optional
                 .body("body")
                 .headers(Map.of(
                         "headersKey", "headers"))
                 .output(Map.of(
                         "outputKey", "output"))
                 .build())
         .sequentialExecutorConfiguration(SequentialExecutorConfigurationProperty.builder()
                 .functionList(List.of(FunctionRefProperty.builder()
                         .functionId("functionId")
                         .runCondition("runCondition")
                         .build()))
                 .runtime("runtime")
                 .timeoutMilliseconds(123)
                 // the properties below are optional
                 .output(Map.of(
                         "outputKey", "output"))
                 .build())
         .tags(List.of(CfnTag.builder()
                 .key("key")
                 .value("value")
                 .build()))
         .build();
 

See Also:
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnFunction

      protected CfnFunction(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnFunction

      protected CfnFunction(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnFunction

      @Stability(Stable) public CfnFunction(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnFunctionProps props)
      Create a new AWS::MediaTailor::Function.

      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

    • arnForFunction

      @Stability(Stable) @NotNull public static String arnForFunction(@NotNull IFunctionRef resource)
      Parameters:
      resource - This parameter is required.
    • isCfnFunction

      @Stability(Stable) @NotNull public static Boolean isCfnFunction(@NotNull Object x)
      Checks whether the given object is a CfnFunction.

      Parameters:
      x - This parameter is required.
    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      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:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrArn

      @Stability(Stable) @NotNull public String getAttrArn()
      The ARN of the function.
    • getCdkTagManager

      @Stability(Stable) @NotNull public TagManager getCdkTagManager()
      Tag Manager which manages the tags for this resource.
      Specified by:
      getCdkTagManager in interface ITaggableV2
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getCfnPropertyNames

      @Stability(Stable) @NotNull protected Map<String,String> getCfnPropertyNames()
      Overrides:
      getCfnPropertyNames in class CfnResource
    • getFunctionRef

      @Stability(Stable) @NotNull public FunctionReference getFunctionRef()
      A reference to a Function resource.
      Specified by:
      getFunctionRef in interface IFunctionRef
    • getFunctionId

      @Stability(Stable) @NotNull public String getFunctionId()
      The unique identifier for the function.
    • setFunctionId

      @Stability(Stable) public void setFunctionId(@NotNull String value)
      The unique identifier for the function.
    • getFunctionType

      @Stability(Stable) @NotNull public String getFunctionType()
    • setFunctionType

      @Stability(Stable) public void setFunctionType(@NotNull String value)
    • getCustomOutputConfiguration

      @Stability(Stable) @Nullable public Object getCustomOutputConfiguration()
      Configuration for custom output functions.

      Returns union: either IResolvable or CfnFunction.CustomOutputConfigurationProperty

    • setCustomOutputConfiguration

      @Stability(Stable) public void setCustomOutputConfiguration(@Nullable IResolvable value)
      Configuration for custom output functions.
    • setCustomOutputConfiguration

      @Stability(Stable) public void setCustomOutputConfiguration(@Nullable CfnFunction.CustomOutputConfigurationProperty value)
      Configuration for custom output functions.
    • getDescription

      @Stability(Stable) @Nullable public String getDescription()
      A description of the function.
    • setDescription

      @Stability(Stable) public void setDescription(@Nullable String value)
      A description of the function.
    • getHttpRequestConfiguration

      @Stability(Stable) @Nullable public Object getHttpRequestConfiguration()
      Configuration for HTTP request functions.

      Returns union: either IResolvable or CfnFunction.HttpRequestConfigurationProperty

    • setHttpRequestConfiguration

      @Stability(Stable) public void setHttpRequestConfiguration(@Nullable IResolvable value)
      Configuration for HTTP request functions.
    • setHttpRequestConfiguration

      @Stability(Stable) public void setHttpRequestConfiguration(@Nullable CfnFunction.HttpRequestConfigurationProperty value)
      Configuration for HTTP request functions.
    • getSequentialExecutorConfiguration

      @Stability(Stable) @Nullable public Object getSequentialExecutorConfiguration()
      Configuration for sequential executor functions.

      Returns union: either IResolvable or CfnFunction.SequentialExecutorConfigurationProperty

    • setSequentialExecutorConfiguration

      @Stability(Stable) public void setSequentialExecutorConfiguration(@Nullable IResolvable value)
      Configuration for sequential executor functions.
    • setSequentialExecutorConfiguration

      @Stability(Stable) public void setSequentialExecutorConfiguration(@Nullable CfnFunction.SequentialExecutorConfigurationProperty value)
      Configuration for sequential executor functions.
    • getTags

      @Stability(Stable) @Nullable public List<CfnTag> getTags()
      The tags to assign to the function resource.
    • setTags

      @Stability(Stable) public void setTags(@Nullable List<CfnTag> value)
      The tags to assign to the function resource.