Class LambdaFunctionAssociation.Builder
java.lang.Object
software.amazon.awscdk.services.cloudfront.LambdaFunctionAssociation.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<LambdaFunctionAssociation>
- Enclosing interface:
LambdaFunctionAssociation
@Stability(Stable)
public static final class LambdaFunctionAssociation.Builder
extends Object
implements software.amazon.jsii.Builder<LambdaFunctionAssociation>
A builder for
LambdaFunctionAssociation-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.eventType(LambdaEdgeEventType eventType) Sets the value ofLambdaFunctionAssociation.getEventType()includeBody(Boolean includeBody) Sets the value ofLambdaFunctionAssociation.getIncludeBody()lambdaFunction(IVersion lambdaFunction) Sets the value ofLambdaFunctionAssociation.getLambdaFunction()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
eventType
@Stability(Stable) public LambdaFunctionAssociation.Builder eventType(LambdaEdgeEventType eventType) Sets the value ofLambdaFunctionAssociation.getEventType()- Parameters:
eventType- The lambda event type defines at which event the lambda is called during the request lifecycle. This parameter is required.- Returns:
this
-
lambdaFunction
Sets the value ofLambdaFunctionAssociation.getLambdaFunction()- Parameters:
lambdaFunction- A version of the lambda to associate. This parameter is required.- Returns:
this
-
includeBody
Sets the value ofLambdaFunctionAssociation.getIncludeBody()- Parameters:
includeBody- Allows a Lambda function to have read access to the body content. Only valid for "request" event types (ORIGIN_REQUESTorVIEWER_REQUEST).- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<LambdaFunctionAssociation>- Returns:
- a new instance of
LambdaFunctionAssociation - Throws:
NullPointerException- if any required attribute was not provided
-