java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.codebuild.Source
All Implemented Interfaces:
ISource, software.amazon.jsii.JsiiSerializable

@Generated(value="jsii-pacmak/1.96.0 (build 921e240)", date="2024-04-10T22:22:25.173Z") @Stability(Stable) public abstract class Source extends software.amazon.jsii.JsiiObject implements ISource
Source provider definition for a CodeBuild Project.

Example:

 Project project = Project.Builder.create(this, "MyProject")
         .buildSpec(BuildSpec.fromSourceFilename("my-buildspec.yml"))
         .source(Source.gitHub(GitHubSourceProps.builder()
                 .owner("awslabs")
                 .repo("aws-cdk")
                 .build()))
         .build();
 
  • Constructor Details

    • Source

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

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

      @Stability(Stable) protected Source(@NotNull SourceProps props)
      Parameters:
      props - This parameter is required.
  • Method Details

    • bitBucket

      @Stability(Stable) @NotNull public static ISource bitBucket(@NotNull BitBucketSourceProps props)
      Parameters:
      props - This parameter is required.
    • codeCommit

      @Stability(Stable) @NotNull public static ISource codeCommit(@NotNull CodeCommitSourceProps props)
      Parameters:
      props - This parameter is required.
    • gitHub

      @Stability(Stable) @NotNull public static ISource gitHub(@NotNull GitHubSourceProps props)
      Parameters:
      props - This parameter is required.
    • gitHubEnterprise

      @Stability(Stable) @NotNull public static ISource gitHubEnterprise(@NotNull GitHubEnterpriseSourceProps props)
      Parameters:
      props - This parameter is required.
    • s3

      @Stability(Stable) @NotNull public static ISource s3(@NotNull S3SourceProps props)
      Parameters:
      props - This parameter is required.
    • bind

      @Stability(Stable) @NotNull public SourceConfig bind(@NotNull software.constructs.Construct _scope, @NotNull IProject _project)
      Called by the project when the source is added so that the source can perform binding operations on the source.

      For example, it can grant permissions to the code build project to read from the S3 bucket.

      Specified by:
      bind in interface ISource
      Parameters:
      _scope - This parameter is required.
      _project - This parameter is required.
    • getBadgeSupported

      @Stability(Stable) @NotNull public Boolean getBadgeSupported()
      Specified by:
      getBadgeSupported in interface ISource
    • getType

      @Stability(Stable) @NotNull public abstract String getType()
      Specified by:
      getType in interface ISource
    • getIdentifier

      @Stability(Stable) @Nullable public String getIdentifier()
      Specified by:
      getIdentifier in interface ISource