Class DefaultServiceAccount.Builder (3.85.0)

public static final class DefaultServiceAccount.Builder extends GeneratedMessage.Builder<DefaultServiceAccount.Builder> implements DefaultServiceAccountOrBuilder

The default service account used for Builds.

Protobuf type google.devtools.cloudbuild.v1.DefaultServiceAccount

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

build()

public DefaultServiceAccount build()
Returns
Type Description
DefaultServiceAccount

buildPartial()

public DefaultServiceAccount buildPartial()
Returns
Type Description
DefaultServiceAccount

clear()

public DefaultServiceAccount.Builder clear()
Returns
Type Description
DefaultServiceAccount.Builder
Overrides

clearName()

public DefaultServiceAccount.Builder clearName()

Identifier. Format: projects/{project}/locations/{location}/defaultServiceAccount

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
DefaultServiceAccount.Builder

This builder for chaining.

clearServiceAccountEmail()

public DefaultServiceAccount.Builder clearServiceAccountEmail()

Output only. The email address of the service account identity that will be used for a build by default.

This is returned in the format projects/{project}/serviceAccounts/{service_account} where {service_account} could be the legacy Cloud Build SA, in the format [PROJECT_NUMBER]@cloudbuild.gserviceaccount.com or the Compute SA, in the format [PROJECT_NUMBER]-compute@developer.gserviceaccount.com.

If no service account will be used by default, this will be empty.

string service_account_email = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Returns
Type Description
DefaultServiceAccount.Builder

This builder for chaining.

getDefaultInstanceForType()

public DefaultServiceAccount getDefaultInstanceForType()
Returns
Type Description
DefaultServiceAccount

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getName()

public String getName()

Identifier. Format: projects/{project}/locations/{location}/defaultServiceAccount

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Identifier. Format: projects/{project}/locations/{location}/defaultServiceAccount

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
ByteString

The bytes for name.

getServiceAccountEmail()

public String getServiceAccountEmail()

Output only. The email address of the service account identity that will be used for a build by default.

This is returned in the format projects/{project}/serviceAccounts/{service_account} where {service_account} could be the legacy Cloud Build SA, in the format [PROJECT_NUMBER]@cloudbuild.gserviceaccount.com or the Compute SA, in the format [PROJECT_NUMBER]-compute@developer.gserviceaccount.com.

If no service account will be used by default, this will be empty.

string service_account_email = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Returns
Type Description
String

The serviceAccountEmail.

getServiceAccountEmailBytes()

public ByteString getServiceAccountEmailBytes()

Output only. The email address of the service account identity that will be used for a build by default.

This is returned in the format projects/{project}/serviceAccounts/{service_account} where {service_account} could be the legacy Cloud Build SA, in the format [PROJECT_NUMBER]@cloudbuild.gserviceaccount.com or the Compute SA, in the format [PROJECT_NUMBER]-compute@developer.gserviceaccount.com.

If no service account will be used by default, this will be empty.

string service_account_email = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Returns
Type Description
ByteString

The bytes for serviceAccountEmail.

internalGetFieldAccessorTable()

protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(DefaultServiceAccount other)

public DefaultServiceAccount.Builder mergeFrom(DefaultServiceAccount other)
Parameter
Name Description
other DefaultServiceAccount
Returns
Type Description
DefaultServiceAccount.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public DefaultServiceAccount.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
DefaultServiceAccount.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public DefaultServiceAccount.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
DefaultServiceAccount.Builder
Overrides

setName(String value)

public DefaultServiceAccount.Builder setName(String value)

Identifier. Format: projects/{project}/locations/{location}/defaultServiceAccount

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value String

The name to set.

Returns
Type Description
DefaultServiceAccount.Builder

This builder for chaining.

setNameBytes(ByteString value)

public DefaultServiceAccount.Builder setNameBytes(ByteString value)

Identifier. Format: projects/{project}/locations/{location}/defaultServiceAccount

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
DefaultServiceAccount.Builder

This builder for chaining.

setServiceAccountEmail(String value)

public DefaultServiceAccount.Builder setServiceAccountEmail(String value)

Output only. The email address of the service account identity that will be used for a build by default.

This is returned in the format projects/{project}/serviceAccounts/{service_account} where {service_account} could be the legacy Cloud Build SA, in the format [PROJECT_NUMBER]@cloudbuild.gserviceaccount.com or the Compute SA, in the format [PROJECT_NUMBER]-compute@developer.gserviceaccount.com.

If no service account will be used by default, this will be empty.

string service_account_email = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The serviceAccountEmail to set.

Returns
Type Description
DefaultServiceAccount.Builder

This builder for chaining.

setServiceAccountEmailBytes(ByteString value)

public DefaultServiceAccount.Builder setServiceAccountEmailBytes(ByteString value)

Output only. The email address of the service account identity that will be used for a build by default.

This is returned in the format projects/{project}/serviceAccounts/{service_account} where {service_account} could be the legacy Cloud Build SA, in the format [PROJECT_NUMBER]@cloudbuild.gserviceaccount.com or the Compute SA, in the format [PROJECT_NUMBER]-compute@developer.gserviceaccount.com.

If no service account will be used by default, this will be empty.

string service_account_email = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes for serviceAccountEmail to set.

Returns
Type Description
DefaultServiceAccount.Builder

This builder for chaining.