Class Resolver.Builder

java.lang.Object
software.amazon.awscdk.services.appsync.Resolver.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<Resolver>
Enclosing class:
Resolver

@Stability(Stable) public static final class Resolver.Builder extends Object implements software.amazon.jsii.Builder<Resolver>
A fluent builder for Resolver.
  • Method Details

    • create

      @Stability(Stable) public static Resolver.Builder create(software.constructs.Construct scope, String id)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      Returns:
      a new instance of Resolver.Builder.
    • fieldName

      @Stability(Stable) public Resolver.Builder fieldName(String fieldName)
      name of the GraphQL field in the given type this resolver is attached to.

      Parameters:
      fieldName - name of the GraphQL field in the given type this resolver is attached to. This parameter is required.
      Returns:
      this
    • typeName

      @Stability(Stable) public Resolver.Builder typeName(String typeName)
      name of the GraphQL type this resolver is attached to.

      Parameters:
      typeName - name of the GraphQL type this resolver is attached to. This parameter is required.
      Returns:
      this
    • cachingConfig

      @Stability(Stable) public Resolver.Builder cachingConfig(CachingConfig cachingConfig)
      The caching configuration for this resolver.

      Default: - No caching configuration

      Parameters:
      cachingConfig - The caching configuration for this resolver. This parameter is required.
      Returns:
      this
    • code

      @Stability(Stable) public Resolver.Builder code(Code code)
      The function code.

      Default: - no code is used

      Parameters:
      code - The function code. This parameter is required.
      Returns:
      this
    • maxBatchSize

      @Stability(Stable) public Resolver.Builder maxBatchSize(Number maxBatchSize)
      The maximum number of elements per batch, when using batch invoke.

      Default: - No max batch size

      Parameters:
      maxBatchSize - The maximum number of elements per batch, when using batch invoke. This parameter is required.
      Returns:
      this
    • pipelineConfig

      @Stability(Stable) public Resolver.Builder pipelineConfig(List<? extends IAppsyncFunction> pipelineConfig)
      configuration of the pipeline resolver.

      Default: - no pipeline resolver configuration An empty array | undefined sets resolver to be of kind, unit

      Parameters:
      pipelineConfig - configuration of the pipeline resolver. This parameter is required.
      Returns:
      this
    • requestMappingTemplate

      @Stability(Stable) public Resolver.Builder requestMappingTemplate(MappingTemplate requestMappingTemplate)
      The request mapping template for this resolver.

      Default: - No mapping template

      Parameters:
      requestMappingTemplate - The request mapping template for this resolver. This parameter is required.
      Returns:
      this
    • responseMappingTemplate

      @Stability(Stable) public Resolver.Builder responseMappingTemplate(MappingTemplate responseMappingTemplate)
      The response mapping template for this resolver.

      Default: - No mapping template

      Parameters:
      responseMappingTemplate - The response mapping template for this resolver. This parameter is required.
      Returns:
      this
    • runtime

      @Stability(Stable) public Resolver.Builder runtime(FunctionRuntime runtime)
      The functions runtime.

      Default: - no function runtime, VTL mapping templates used

      Parameters:
      runtime - The functions runtime. This parameter is required.
      Returns:
      this
    • dataSource

      @Stability(Stable) public Resolver.Builder dataSource(BaseDataSource dataSource)
      The data source this resolver is using.

      Default: - No datasource

      Parameters:
      dataSource - The data source this resolver is using. This parameter is required.
      Returns:
      this
    • api

      @Stability(Stable) public Resolver.Builder api(IGraphqlApi api)
      The API this resolver is attached to.

      Parameters:
      api - The API this resolver is attached to. This parameter is required.
      Returns:
      this
    • build

      @Stability(Stable) public Resolver build()
      Specified by:
      build in interface software.amazon.jsii.Builder<Resolver>
      Returns:
      a newly built instance of Resolver.