Class GitHubEnterpriseSourceProps.Builder
java.lang.Object
software.amazon.awscdk.services.codebuild.GitHubEnterpriseSourceProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<GitHubEnterpriseSourceProps>
- Enclosing interface:
GitHubEnterpriseSourceProps
@Stability(Stable)
public static final class GitHubEnterpriseSourceProps.Builder
extends Object
implements software.amazon.jsii.Builder<GitHubEnterpriseSourceProps>
A builder for
GitHubEnterpriseSourceProps
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbranchOrRef
(String branchOrRef) Sets the value ofGitHubEnterpriseSourceProps.getBranchOrRef()
build()
Builds the configured instance.buildStatusContext
(String buildStatusContext) Sets the value ofGitHubEnterpriseSourceProps.getBuildStatusContext()
buildStatusUrl
(String buildStatusUrl) Sets the value ofGitHubEnterpriseSourceProps.getBuildStatusUrl()
cloneDepth
(Number cloneDepth) Sets the value ofGitHubEnterpriseSourceProps.getCloneDepth()
fetchSubmodules
(Boolean fetchSubmodules) Sets the value ofGitHubEnterpriseSourceProps.getFetchSubmodules()
httpsCloneUrl
(String httpsCloneUrl) Sets the value ofGitHubEnterpriseSourceProps.getHttpsCloneUrl()
identifier
(String identifier) Sets the value ofSourceProps.getIdentifier()
ignoreSslErrors
(Boolean ignoreSslErrors) Sets the value ofGitHubEnterpriseSourceProps.getIgnoreSslErrors()
reportBuildStatus
(Boolean reportBuildStatus) Sets the value ofGitHubEnterpriseSourceProps.getReportBuildStatus()
Sets the value ofGitHubEnterpriseSourceProps.getWebhook()
webhookFilters
(List<? extends FilterGroup> webhookFilters) Sets the value ofGitHubEnterpriseSourceProps.getWebhookFilters()
webhookTriggersBatchBuild
(Boolean webhookTriggersBatchBuild) Sets the value ofGitHubEnterpriseSourceProps.getWebhookTriggersBatchBuild()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
httpsCloneUrl
Sets the value ofGitHubEnterpriseSourceProps.getHttpsCloneUrl()
- Parameters:
httpsCloneUrl
- The HTTPS URL of the repository in your GitHub Enterprise installation. This parameter is required.- Returns:
this
-
branchOrRef
Sets the value ofGitHubEnterpriseSourceProps.getBranchOrRef()
- Parameters:
branchOrRef
- The commit ID, pull request ID, branch name, or tag name that corresponds to the version of the source code you want to build.- Returns:
this
-
buildStatusContext
@Stability(Stable) public GitHubEnterpriseSourceProps.Builder buildStatusContext(String buildStatusContext) Sets the value ofGitHubEnterpriseSourceProps.getBuildStatusContext()
- Parameters:
buildStatusContext
- This parameter is used for thecontext
parameter in the GitHub commit status. Can use built-in CodeBuild variables, like $AWS_REGION.- Returns:
this
-
buildStatusUrl
Sets the value ofGitHubEnterpriseSourceProps.getBuildStatusUrl()
- Parameters:
buildStatusUrl
- The URL that the build will report back to the source provider. Can use built-in CodeBuild variables, like $AWS_REGION.- Returns:
this
-
cloneDepth
Sets the value ofGitHubEnterpriseSourceProps.getCloneDepth()
- Parameters:
cloneDepth
- The depth of history to download. Minimum value is 0. If this value is 0, greater than 25, or not provided, then the full history is downloaded with each build of the project.- Returns:
this
-
fetchSubmodules
@Stability(Stable) public GitHubEnterpriseSourceProps.Builder fetchSubmodules(Boolean fetchSubmodules) Sets the value ofGitHubEnterpriseSourceProps.getFetchSubmodules()
- Parameters:
fetchSubmodules
- Whether to fetch submodules while cloning git repo.- Returns:
this
-
ignoreSslErrors
@Stability(Stable) public GitHubEnterpriseSourceProps.Builder ignoreSslErrors(Boolean ignoreSslErrors) Sets the value ofGitHubEnterpriseSourceProps.getIgnoreSslErrors()
- Parameters:
ignoreSslErrors
- Whether to ignore SSL errors when connecting to the repository.- Returns:
this
-
reportBuildStatus
@Stability(Stable) public GitHubEnterpriseSourceProps.Builder reportBuildStatus(Boolean reportBuildStatus) Sets the value ofGitHubEnterpriseSourceProps.getReportBuildStatus()
- Parameters:
reportBuildStatus
- Whether to send notifications on your build's start and end.- Returns:
this
-
webhook
Sets the value ofGitHubEnterpriseSourceProps.getWebhook()
- Parameters:
webhook
- Whether to create a webhook that will trigger a build every time an event happens in the repository.- Returns:
this
-
webhookFilters
@Stability(Stable) public GitHubEnterpriseSourceProps.Builder webhookFilters(List<? extends FilterGroup> webhookFilters) Sets the value ofGitHubEnterpriseSourceProps.getWebhookFilters()
- Parameters:
webhookFilters
- A list of webhook filters that can constraint what events in the repository will trigger a build. A build is triggered if any of the provided filter groups match. Only valid ifwebhook
was not provided as false.- Returns:
this
-
webhookTriggersBatchBuild
@Stability(Stable) public GitHubEnterpriseSourceProps.Builder webhookTriggersBatchBuild(Boolean webhookTriggersBatchBuild) Sets the value ofGitHubEnterpriseSourceProps.getWebhookTriggersBatchBuild()
- Parameters:
webhookTriggersBatchBuild
- Trigger a batch build from a webhook instead of a standard one. Enabling this will enable batch builds on the CodeBuild project.- Returns:
this
-
identifier
Sets the value ofSourceProps.getIdentifier()
- Parameters:
identifier
- The source identifier. This property is required on secondary sources.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<GitHubEnterpriseSourceProps>
- Returns:
- a new instance of
GitHubEnterpriseSourceProps
- Throws:
NullPointerException
- if any required attribute was not provided
-