Class ApiIntegration.Builder
java.lang.Object
software.amazon.awsconstructs.services.openapigatewaylambda.ApiIntegration.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<ApiIntegration>
- Enclosing interface:
ApiIntegration
public static final class ApiIntegration.Builder
extends Object
implements software.amazon.jsii.Builder<ApiIntegration>
A builder for
ApiIntegration-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.existingLambdaObj(software.amazon.awscdk.services.lambda.Alias existingLambdaObj) Sets the value ofApiIntegration.getExistingLambdaObj()existingLambdaObj(software.amazon.awscdk.services.lambda.Function existingLambdaObj) Sets the value ofApiIntegration.getExistingLambdaObj()Sets the value ofApiIntegration.getId()lambdaFunctionProps(software.amazon.awscdk.services.lambda.FunctionProps lambdaFunctionProps) Sets the value ofApiIntegration.getLambdaFunctionProps()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
id
Sets the value ofApiIntegration.getId()- Parameters:
id- Id of the ApiIntegration, used to correlate this lambda function to the api integration in the open api definition. This parameter is required. Note this is not a CDK Construct ID, and is instead a client defined string used to map the resolved lambda resource with the OpenAPI definition.- Returns:
this
-
existingLambdaObj
public ApiIntegration.Builder existingLambdaObj(software.amazon.awscdk.services.lambda.Function existingLambdaObj) Sets the value ofApiIntegration.getExistingLambdaObj()- Parameters:
existingLambdaObj- The Lambda function to associate with the API method in the OpenAPI file matched by id. One and only one of existingLambdaObj or lambdaFunctionProps must be specified, any other combination will cause an error.- Returns:
this
-
existingLambdaObj
public ApiIntegration.Builder existingLambdaObj(software.amazon.awscdk.services.lambda.Alias existingLambdaObj) Sets the value ofApiIntegration.getExistingLambdaObj()- Parameters:
existingLambdaObj- The Lambda function to associate with the API method in the OpenAPI file matched by id. One and only one of existingLambdaObj or lambdaFunctionProps must be specified, any other combination will cause an error.- Returns:
this
-
lambdaFunctionProps
public ApiIntegration.Builder lambdaFunctionProps(software.amazon.awscdk.services.lambda.FunctionProps lambdaFunctionProps) Sets the value ofApiIntegration.getLambdaFunctionProps()- Parameters:
lambdaFunctionProps- Properties for the Lambda function to create and associate with the API method in the OpenAPI file matched by id. One and only one of existingLambdaObj or lambdaFunctionProps must be specified, any other combination will cause an error.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<ApiIntegration>- Returns:
- a new instance of
ApiIntegration - Throws:
NullPointerException- if any required attribute was not provided
-