@Generated(value="software.amazon.awssdk:codegen") public final class Build extends Object implements SdkPojo, Serializable, ToCopyableBuilder<Build.Builder,Build>
Information about a build.
| Modifier and Type | Class and Description |
|---|---|
static interface |
Build.Builder |
| Modifier and Type | Method and Description |
|---|---|
String |
arn()
The Amazon Resource Name (ARN) of the build.
|
BuildArtifacts |
artifacts()
Information about the output artifacts for the build.
|
String |
buildBatchArn()
The ARN of the batch build that this build is a member of, if applicable.
|
Boolean |
buildComplete()
Whether the build is complete.
|
static Build.Builder |
builder() |
Long |
buildNumber()
The number of the build.
|
StatusType |
buildStatus()
The current status of the build.
|
String |
buildStatusAsString()
The current status of the build.
|
ProjectCache |
cache()
Information about the cache for the build.
|
String |
currentPhase()
The current build phase.
|
DebugSession |
debugSession()
Contains information about the debug session for this build.
|
String |
encryptionKey()
The Key Management Service customer master key (CMK) to be used for encrypting the build output artifacts.
|
Instant |
endTime()
When the build process ended, expressed in Unix time format.
|
ProjectEnvironment |
environment()
Information about the build environment for this build.
|
boolean |
equals(Object obj) |
boolean |
equalsBySdkFields(Object obj) |
List<ExportedEnvironmentVariable> |
exportedEnvironmentVariables()
A list of exported environment variables for this build.
|
List<ProjectFileSystemLocation> |
fileSystemLocations()
An array of
ProjectFileSystemLocation objects for a CodeBuild build project. |
<T> Optional<T> |
getValueForField(String fieldName,
Class<T> clazz) |
boolean |
hasExportedEnvironmentVariables()
For responses, this returns true if the service returned a value for the ExportedEnvironmentVariables property.
|
boolean |
hasFileSystemLocations()
For responses, this returns true if the service returned a value for the FileSystemLocations property.
|
int |
hashCode() |
boolean |
hasPhases()
For responses, this returns true if the service returned a value for the Phases property.
|
boolean |
hasReportArns()
For responses, this returns true if the service returned a value for the ReportArns property.
|
boolean |
hasSecondaryArtifacts()
For responses, this returns true if the service returned a value for the SecondaryArtifacts property.
|
boolean |
hasSecondarySources()
For responses, this returns true if the service returned a value for the SecondarySources property.
|
boolean |
hasSecondarySourceVersions()
For responses, this returns true if the service returned a value for the SecondarySourceVersions property.
|
String |
id()
The unique ID for the build.
|
String |
initiator()
The entity that started the build.
|
LogsLocation |
logs()
Information about the build's logs in CloudWatch Logs.
|
NetworkInterface |
networkInterface()
Describes a network interface.
|
List<BuildPhase> |
phases()
Information about all previous build phases that are complete and information about any current build phase that
is not yet complete.
|
String |
projectName()
The name of the CodeBuild project.
|
Integer |
queuedTimeoutInMinutes()
The number of minutes a build is allowed to be queued before it times out.
|
List<String> |
reportArns()
An array of the ARNs associated with this build's reports.
|
String |
resolvedSourceVersion()
An identifier for the version of this build's source code.
|
List<SdkField<?>> |
sdkFields() |
List<BuildArtifacts> |
secondaryArtifacts()
An array of
ProjectArtifacts objects. |
List<ProjectSource> |
secondarySources()
An array of
ProjectSource objects. |
List<ProjectSourceVersion> |
secondarySourceVersions()
An array of
ProjectSourceVersion objects. |
static Class<? extends Build.Builder> |
serializableBuilderClass() |
String |
serviceRole()
The name of a service role used for this build.
|
ProjectSource |
source()
Information about the source code to be built.
|
String |
sourceVersion()
Any version identifier for the version of the source code to be built.
|
Instant |
startTime()
When the build process started, expressed in Unix time format.
|
Integer |
timeoutInMinutes()
How long, in minutes, for CodeBuild to wait before timing out this build if it does not get marked as completed.
|
Build.Builder |
toBuilder() |
String |
toString()
Returns a string representation of this object.
|
VpcConfig |
vpcConfig()
If your CodeBuild project accesses resources in an Amazon VPC, you provide this parameter that identifies the VPC
ID and the list of security group IDs and subnet IDs.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, waitcopypublic final String id()
The unique ID for the build.
public final String arn()
The Amazon Resource Name (ARN) of the build.
public final Long buildNumber()
The number of the build. For each project, the buildNumber of its first build is 1. The
buildNumber of each subsequent build is incremented by 1. If a build is deleted, the
buildNumber of other builds does not change.
buildNumber of its first build is
1. The buildNumber of each subsequent build is incremented by 1.
If a build is deleted, the buildNumber of other builds does not change.public final Instant startTime()
When the build process started, expressed in Unix time format.
public final Instant endTime()
When the build process ended, expressed in Unix time format.
public final String currentPhase()
The current build phase.
public final StatusType buildStatus()
The current status of the build. Valid values include:
FAILED: The build failed.
FAULT: The build faulted.
IN_PROGRESS: The build is still in progress.
STOPPED: The build stopped.
SUCCEEDED: The build succeeded.
TIMED_OUT: The build timed out.
If the service returns an enum value that is not available in the current SDK version, buildStatus will
return StatusType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
buildStatusAsString().
FAILED: The build failed.
FAULT: The build faulted.
IN_PROGRESS: The build is still in progress.
STOPPED: The build stopped.
SUCCEEDED: The build succeeded.
TIMED_OUT: The build timed out.
StatusTypepublic final String buildStatusAsString()
The current status of the build. Valid values include:
FAILED: The build failed.
FAULT: The build faulted.
IN_PROGRESS: The build is still in progress.
STOPPED: The build stopped.
SUCCEEDED: The build succeeded.
TIMED_OUT: The build timed out.
If the service returns an enum value that is not available in the current SDK version, buildStatus will
return StatusType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
buildStatusAsString().
FAILED: The build failed.
FAULT: The build faulted.
IN_PROGRESS: The build is still in progress.
STOPPED: The build stopped.
SUCCEEDED: The build succeeded.
TIMED_OUT: The build timed out.
StatusTypepublic final String sourceVersion()
Any version identifier for the version of the source code to be built. If sourceVersion is specified
at the project level, then this sourceVersion (at the build level) takes precedence.
For more information, see Source Version Sample with CodeBuild in the CodeBuild User Guide.
sourceVersion is
specified at the project level, then this sourceVersion (at the build level) takes
precedence.
For more information, see Source Version Sample with CodeBuild in the CodeBuild User Guide.
public final String resolvedSourceVersion()
An identifier for the version of this build's source code.
For CodeCommit, GitHub, GitHub Enterprise, and BitBucket, the commit ID.
For CodePipeline, the source revision provided by CodePipeline.
For Amazon S3, this does not apply.
For CodeCommit, GitHub, GitHub Enterprise, and BitBucket, the commit ID.
For CodePipeline, the source revision provided by CodePipeline.
For Amazon S3, this does not apply.
public final String projectName()
The name of the CodeBuild project.
public final boolean hasPhases()
isEmpty() method on the property). This is
useful because the SDK will never return a null collection or map, but you may need to differentiate between the
service returning nothing (or null) and the service returning an empty collection or map. For requests, this
returns true if a value for the property was specified in the request builder, and false if a value was not
specified.public final List<BuildPhase> phases()
Information about all previous build phases that are complete and information about any current build phase that is not yet complete.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasPhases() method.
public final ProjectSource source()
Information about the source code to be built.
public final boolean hasSecondarySources()
isEmpty() method on the property).
This is useful because the SDK will never return a null collection or map, but you may need to differentiate
between the service returning nothing (or null) and the service returning an empty collection or map. For
requests, this returns true if a value for the property was specified in the request builder, and false if a
value was not specified.public final List<ProjectSource> secondarySources()
An array of ProjectSource objects.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasSecondarySources() method.
ProjectSource objects.public final boolean hasSecondarySourceVersions()
isEmpty() method on the
property). This is useful because the SDK will never return a null collection or map, but you may need to
differentiate between the service returning nothing (or null) and the service returning an empty collection or
map. For requests, this returns true if a value for the property was specified in the request builder, and false
if a value was not specified.public final List<ProjectSourceVersion> secondarySourceVersions()
An array of ProjectSourceVersion objects. Each ProjectSourceVersion must be one of:
For CodeCommit: the commit ID, branch, or Git tag to use.
For GitHub: the commit ID, pull request ID, branch name, or tag name that corresponds to the version of the
source code you want to build. If a pull request ID is specified, it must use the format
pr/pull-request-ID (for example, pr/25). If a branch name is specified, the branch's
HEAD commit ID is used. If not specified, the default branch's HEAD commit ID is used.
For Bitbucket: the commit ID, branch name, or tag name that corresponds to the version of the source code you want to build. If a branch name is specified, the branch's HEAD commit ID is used. If not specified, the default branch's HEAD commit ID is used.
For Amazon S3: the version ID of the object that represents the build input ZIP file to use.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasSecondarySourceVersions() method.
ProjectSourceVersion objects. Each ProjectSourceVersion must be one
of:
For CodeCommit: the commit ID, branch, or Git tag to use.
For GitHub: the commit ID, pull request ID, branch name, or tag name that corresponds to the version of
the source code you want to build. If a pull request ID is specified, it must use the format
pr/pull-request-ID (for example, pr/25). If a branch name is specified, the
branch's HEAD commit ID is used. If not specified, the default branch's HEAD commit ID is used.
For Bitbucket: the commit ID, branch name, or tag name that corresponds to the version of the source code you want to build. If a branch name is specified, the branch's HEAD commit ID is used. If not specified, the default branch's HEAD commit ID is used.
For Amazon S3: the version ID of the object that represents the build input ZIP file to use.
public final BuildArtifacts artifacts()
Information about the output artifacts for the build.
public final boolean hasSecondaryArtifacts()
isEmpty() method on the property).
This is useful because the SDK will never return a null collection or map, but you may need to differentiate
between the service returning nothing (or null) and the service returning an empty collection or map. For
requests, this returns true if a value for the property was specified in the request builder, and false if a
value was not specified.public final List<BuildArtifacts> secondaryArtifacts()
An array of ProjectArtifacts objects.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasSecondaryArtifacts() method.
ProjectArtifacts objects.public final ProjectCache cache()
Information about the cache for the build.
public final ProjectEnvironment environment()
Information about the build environment for this build.
public final String serviceRole()
The name of a service role used for this build.
public final LogsLocation logs()
Information about the build's logs in CloudWatch Logs.
public final Integer timeoutInMinutes()
How long, in minutes, for CodeBuild to wait before timing out this build if it does not get marked as completed.
public final Integer queuedTimeoutInMinutes()
The number of minutes a build is allowed to be queued before it times out.
public final Boolean buildComplete()
Whether the build is complete. True if complete; otherwise, false.
public final String initiator()
The entity that started the build. Valid values include:
If CodePipeline started the build, the pipeline's name (for example, codepipeline/my-demo-pipeline).
If an IAM user started the build, the user's name (for example, MyUserName).
If the Jenkins plugin for CodeBuild started the build, the string CodeBuild-Jenkins-Plugin.
If CodePipeline started the build, the pipeline's name (for example,
codepipeline/my-demo-pipeline).
If an IAM user started the build, the user's name (for example, MyUserName).
If the Jenkins plugin for CodeBuild started the build, the string CodeBuild-Jenkins-Plugin.
public final VpcConfig vpcConfig()
If your CodeBuild project accesses resources in an Amazon VPC, you provide this parameter that identifies the VPC ID and the list of security group IDs and subnet IDs. The security groups and subnets must belong to the same VPC. You must provide at least one security group and one subnet ID.
public final NetworkInterface networkInterface()
Describes a network interface.
public final String encryptionKey()
The Key Management Service customer master key (CMK) to be used for encrypting the build output artifacts.
You can use a cross-account KMS key to encrypt the build output artifacts if your service role has permission to that key.
You can specify either the Amazon Resource Name (ARN) of the CMK or, if available, the CMK's alias (using the
format alias/<alias-name>).
You can use a cross-account KMS key to encrypt the build output artifacts if your service role has permission to that key.
You can specify either the Amazon Resource Name (ARN) of the CMK or, if available, the CMK's alias (using
the format alias/<alias-name>).
public final boolean hasExportedEnvironmentVariables()
isEmpty() method on the
property). This is useful because the SDK will never return a null collection or map, but you may need to
differentiate between the service returning nothing (or null) and the service returning an empty collection or
map. For requests, this returns true if a value for the property was specified in the request builder, and false
if a value was not specified.public final List<ExportedEnvironmentVariable> exportedEnvironmentVariables()
A list of exported environment variables for this build.
Exported environment variables are used in conjunction with CodePipeline to export environment variables from the current build stage to subsequent stages in the pipeline. For more information, see Working with variables in the CodePipeline User Guide.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasExportedEnvironmentVariables() method.
Exported environment variables are used in conjunction with CodePipeline to export environment variables from the current build stage to subsequent stages in the pipeline. For more information, see Working with variables in the CodePipeline User Guide.
public final boolean hasReportArns()
isEmpty() method on the property). This is
useful because the SDK will never return a null collection or map, but you may need to differentiate between the
service returning nothing (or null) and the service returning an empty collection or map. For requests, this
returns true if a value for the property was specified in the request builder, and false if a value was not
specified.public final List<String> reportArns()
An array of the ARNs associated with this build's reports.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasReportArns() method.
public final boolean hasFileSystemLocations()
isEmpty() method on the property).
This is useful because the SDK will never return a null collection or map, but you may need to differentiate
between the service returning nothing (or null) and the service returning an empty collection or map. For
requests, this returns true if a value for the property was specified in the request builder, and false if a
value was not specified.public final List<ProjectFileSystemLocation> fileSystemLocations()
An array of ProjectFileSystemLocation objects for a CodeBuild build project. A
ProjectFileSystemLocation object specifies the identifier, location,
mountOptions, mountPoint, and type of a file system created using Amazon
Elastic File System.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that
you can differentiate between null and empty), you can use the hasFileSystemLocations() method.
ProjectFileSystemLocation objects for a CodeBuild build project. A
ProjectFileSystemLocation object specifies the identifier,
location, mountOptions, mountPoint, and type of a
file system created using Amazon Elastic File System.public final DebugSession debugSession()
Contains information about the debug session for this build.
public final String buildBatchArn()
The ARN of the batch build that this build is a member of, if applicable.
public Build.Builder toBuilder()
toBuilder in interface ToCopyableBuilder<Build.Builder,Build>public static Build.Builder builder()
public static Class<? extends Build.Builder> serializableBuilderClass()
public final boolean equalsBySdkFields(Object obj)
equalsBySdkFields in interface SdkPojopublic final String toString()
Copyright © 2023. All rights reserved.