Class CreateProjectRequest
- java.lang.Object
-
- software.amazon.awssdk.core.SdkRequest
-
- software.amazon.awssdk.awscore.AwsRequest
-
- software.amazon.awssdk.services.codebuild.model.CodeBuildRequest
-
- software.amazon.awssdk.services.codebuild.model.CreateProjectRequest
-
- All Implemented Interfaces:
SdkPojo,ToCopyableBuilder<CreateProjectRequest.Builder,CreateProjectRequest>
@Generated("software.amazon.awssdk:codegen") public final class CreateProjectRequest extends CodeBuildRequest implements ToCopyableBuilder<CreateProjectRequest.Builder,CreateProjectRequest>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceCreateProjectRequest.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ProjectArtifactsartifacts()Information about the build output artifacts for the build project.BooleanbadgeEnabled()Set this to true to generate a publicly accessible URL for your project's build badge.ProjectBuildBatchConfigbuildBatchConfig()A ProjectBuildBatchConfig object that defines the batch build options for the project.static CreateProjectRequest.Builderbuilder()ProjectCachecache()Stores recently used information so that it can be quickly accessed at a later time.IntegerconcurrentBuildLimit()The maximum number of concurrent builds that are allowed for this project.Stringdescription()A description that makes the build project easy to identify.StringencryptionKey()The Key Management Service customer master key (CMK) to be used for encrypting the build output artifacts.ProjectEnvironmentenvironment()Information about the build environment for the build project.booleanequals(Object obj)booleanequalsBySdkFields(Object obj)List<ProjectFileSystemLocation>fileSystemLocations()An array ofProjectFileSystemLocationobjects for a CodeBuild build project.<T> Optional<T>getValueForField(String fieldName, Class<T> clazz)booleanhasFileSystemLocations()For responses, this returns true if the service returned a value for the FileSystemLocations property.inthashCode()booleanhasSecondaryArtifacts()For responses, this returns true if the service returned a value for the SecondaryArtifacts property.booleanhasSecondarySources()For responses, this returns true if the service returned a value for the SecondarySources property.booleanhasSecondarySourceVersions()For responses, this returns true if the service returned a value for the SecondarySourceVersions property.booleanhasTags()For responses, this returns true if the service returned a value for the Tags property.LogsConfiglogsConfig()Information about logs for the build project.Stringname()The name of the build project.IntegerqueuedTimeoutInMinutes()The number of minutes a build is allowed to be queued before it times out.List<SdkField<?>>sdkFields()List<ProjectArtifacts>secondaryArtifacts()An array ofProjectArtifactsobjects.List<ProjectSource>secondarySources()An array ofProjectSourceobjects.List<ProjectSourceVersion>secondarySourceVersions()An array ofProjectSourceVersionobjects.static Class<? extends CreateProjectRequest.Builder>serializableBuilderClass()StringserviceRole()The ARN of the IAM role that enables CodeBuild to interact with dependent Amazon Web Services services on behalf of the Amazon Web Services account.ProjectSourcesource()Information about the build input source code for the build project.StringsourceVersion()A version of the build input to be built for this project.List<Tag>tags()A list of tag key and value pairs associated with this build project.IntegertimeoutInMinutes()How long, in minutes, from 5 to 480 (8 hours), for CodeBuild to wait before it times out any build that has not been marked as completed.CreateProjectRequest.BuildertoBuilder()StringtoString()Returns a string representation of this object.VpcConfigvpcConfig()VpcConfig enables CodeBuild to access resources in an Amazon VPC.-
Methods inherited from class software.amazon.awssdk.awscore.AwsRequest
overrideConfiguration
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
-
-
-
Method Detail
-
name
public final String name()
The name of the build project.
- Returns:
- The name of the build project.
-
description
public final String description()
A description that makes the build project easy to identify.
- Returns:
- A description that makes the build project easy to identify.
-
source
public final ProjectSource source()
Information about the build input source code for the build project.
- Returns:
- Information about the build input source code for the build project.
-
hasSecondarySources
public final boolean hasSecondarySources()
For responses, this returns true if the service returned a value for the SecondarySources property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()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.
-
secondarySources
public final List<ProjectSource> secondarySources()
An array of
ProjectSourceobjects.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.- Returns:
- An array of
ProjectSourceobjects.
-
sourceVersion
public final String sourceVersion()
A version of the build input to be built for this project. If not specified, the latest version is used. If specified, it 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 examplepr/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.
If
sourceVersionis specified at the build level, then that version takes precedence over thissourceVersion(at the project level).For more information, see Source Version Sample with CodeBuild in the CodeBuild User Guide.
- Returns:
- A version of the build input to be built for this project. If not specified, the latest version is used.
If specified, it 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 examplepr/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.
If
sourceVersionis specified at the build level, then that version takes precedence over thissourceVersion(at the project level).For more information, see Source Version Sample with CodeBuild in the CodeBuild User Guide.
-
-
-
hasSecondarySourceVersions
public final boolean hasSecondarySourceVersions()
For responses, this returns true if the service returned a value for the SecondarySourceVersions property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()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.
-
secondarySourceVersions
public final List<ProjectSourceVersion> secondarySourceVersions()
An array of
ProjectSourceVersionobjects. IfsecondarySourceVersionsis specified at the build level, then they take precedence over thesesecondarySourceVersions(at the project level).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.- Returns:
- An array of
ProjectSourceVersionobjects. IfsecondarySourceVersionsis specified at the build level, then they take precedence over thesesecondarySourceVersions(at the project level).
-
artifacts
public final ProjectArtifacts artifacts()
Information about the build output artifacts for the build project.
- Returns:
- Information about the build output artifacts for the build project.
-
hasSecondaryArtifacts
public final boolean hasSecondaryArtifacts()
For responses, this returns true if the service returned a value for the SecondaryArtifacts property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()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.
-
secondaryArtifacts
public final List<ProjectArtifacts> secondaryArtifacts()
An array of
ProjectArtifactsobjects.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.- Returns:
- An array of
ProjectArtifactsobjects.
-
cache
public final ProjectCache cache()
Stores recently used information so that it can be quickly accessed at a later time.
- Returns:
- Stores recently used information so that it can be quickly accessed at a later time.
-
environment
public final ProjectEnvironment environment()
Information about the build environment for the build project.
- Returns:
- Information about the build environment for the build project.
-
serviceRole
public final String serviceRole()
The ARN of the IAM role that enables CodeBuild to interact with dependent Amazon Web Services services on behalf of the Amazon Web Services account.
- Returns:
- The ARN of the IAM role that enables CodeBuild to interact with dependent Amazon Web Services services on behalf of the Amazon Web Services account.
-
timeoutInMinutes
public final Integer timeoutInMinutes()
How long, in minutes, from 5 to 480 (8 hours), for CodeBuild to wait before it times out any build that has not been marked as completed. The default is 60 minutes.
- Returns:
- How long, in minutes, from 5 to 480 (8 hours), for CodeBuild to wait before it times out any build that has not been marked as completed. The default is 60 minutes.
-
queuedTimeoutInMinutes
public final Integer queuedTimeoutInMinutes()
The number of minutes a build is allowed to be queued before it times out.
- Returns:
- The number of minutes a build is allowed to be queued before it times out.
-
encryptionKey
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>).- Returns:
- 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>).
-
hasTags
public final boolean hasTags()
For responses, this returns true if the service returned a value for the Tags property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()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.
-
tags
public final List<Tag> tags()
A list of tag key and value pairs associated with this build project.
These tags are available for use by Amazon Web Services services that support CodeBuild build project tags.
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
hasTags()method.- Returns:
- A list of tag key and value pairs associated with this build project.
These tags are available for use by Amazon Web Services services that support CodeBuild build project tags.
-
vpcConfig
public final VpcConfig vpcConfig()
VpcConfig enables CodeBuild to access resources in an Amazon VPC.
- Returns:
- VpcConfig enables CodeBuild to access resources in an Amazon VPC.
-
badgeEnabled
public final Boolean badgeEnabled()
Set this to true to generate a publicly accessible URL for your project's build badge.
- Returns:
- Set this to true to generate a publicly accessible URL for your project's build badge.
-
logsConfig
public final LogsConfig logsConfig()
Information about logs for the build project. These can be logs in CloudWatch Logs, logs uploaded to a specified S3 bucket, or both.
- Returns:
- Information about logs for the build project. These can be logs in CloudWatch Logs, logs uploaded to a specified S3 bucket, or both.
-
hasFileSystemLocations
public final boolean hasFileSystemLocations()
For responses, this returns true if the service returned a value for the FileSystemLocations property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()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.
-
fileSystemLocations
public final List<ProjectFileSystemLocation> fileSystemLocations()
An array of
ProjectFileSystemLocationobjects for a CodeBuild build project. AProjectFileSystemLocationobject specifies theidentifier,location,mountOptions,mountPoint, andtypeof 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.- Returns:
- An array of
ProjectFileSystemLocationobjects for a CodeBuild build project. AProjectFileSystemLocationobject specifies theidentifier,location,mountOptions,mountPoint, andtypeof a file system created using Amazon Elastic File System.
-
buildBatchConfig
public final ProjectBuildBatchConfig buildBatchConfig()
A ProjectBuildBatchConfig object that defines the batch build options for the project.
- Returns:
- A ProjectBuildBatchConfig object that defines the batch build options for the project.
-
concurrentBuildLimit
public final Integer concurrentBuildLimit()
The maximum number of concurrent builds that are allowed for this project.
New builds are only started if the current number of builds is less than or equal to this limit. If the current build count meets this limit, new builds are throttled and are not run.
- Returns:
- The maximum number of concurrent builds that are allowed for this project.
New builds are only started if the current number of builds is less than or equal to this limit. If the current build count meets this limit, new builds are throttled and are not run.
-
toBuilder
public CreateProjectRequest.Builder toBuilder()
- Specified by:
toBuilderin interfaceToCopyableBuilder<CreateProjectRequest.Builder,CreateProjectRequest>- Specified by:
toBuilderin classCodeBuildRequest
-
builder
public static CreateProjectRequest.Builder builder()
-
serializableBuilderClass
public static Class<? extends CreateProjectRequest.Builder> serializableBuilderClass()
-
hashCode
public final int hashCode()
- Overrides:
hashCodein classAwsRequest
-
equals
public final boolean equals(Object obj)
- Overrides:
equalsin classAwsRequest
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
getValueForField
public final <T> Optional<T> getValueForField(String fieldName, Class<T> clazz)
- Overrides:
getValueForFieldin classSdkRequest
-
-