Class HostProjectRegistration.Builder (0.2.0)

public static final class HostProjectRegistration.Builder extends GeneratedMessageV3.Builder<HostProjectRegistration.Builder> implements HostProjectRegistrationOrBuilder

Host project registration refers to the registration of a Google cloud project with Api Hub as a host project. This is the project where Api Hub is provisioned. It acts as the consumer project for the Api Hub instance provisioned. Multiple runtime projects can be attached to the host project and these attachments define the scope of Api Hub.

Protobuf type google.cloud.apihub.v1.HostProjectRegistration

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public HostProjectRegistration.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
HostProjectRegistration.Builder
Overrides

build()

public HostProjectRegistration build()
Returns
Type Description
HostProjectRegistration

buildPartial()

public HostProjectRegistration buildPartial()
Returns
Type Description
HostProjectRegistration

clear()

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

clearCreateTime()

public HostProjectRegistration.Builder clearCreateTime()

Output only. The time at which the host project registration was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
HostProjectRegistration.Builder

clearField(Descriptors.FieldDescriptor field)

public HostProjectRegistration.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
HostProjectRegistration.Builder
Overrides

clearGcpProject()

public HostProjectRegistration.Builder clearGcpProject()

Required. Immutable. Google cloud project name in the format: "projects/abc" or "projects/123". As input, project name with either project id or number are accepted. As output, this field will contain project number.

string gcp_project = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... }

Returns
Type Description
HostProjectRegistration.Builder

This builder for chaining.

clearName()

public HostProjectRegistration.Builder clearName()

Identifier. The name of the host project registration. Format: "projects/{project}/locations/{location}/hostProjectRegistrations/{host_project_registration}".

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

Returns
Type Description
HostProjectRegistration.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public HostProjectRegistration.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
HostProjectRegistration.Builder
Overrides

clone()

public HostProjectRegistration.Builder clone()
Returns
Type Description
HostProjectRegistration.Builder
Overrides

getCreateTime()

public Timestamp getCreateTime()

Output only. The time at which the host project registration was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Timestamp

The createTime.

getCreateTimeBuilder()

public Timestamp.Builder getCreateTimeBuilder()

Output only. The time at which the host project registration was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Builder

getCreateTimeOrBuilder()

public TimestampOrBuilder getCreateTimeOrBuilder()

Output only. The time at which the host project registration was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
TimestampOrBuilder

getDefaultInstanceForType()

public HostProjectRegistration getDefaultInstanceForType()
Returns
Type Description
HostProjectRegistration

getDescriptorForType()

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

getGcpProject()

public String getGcpProject()

Required. Immutable. Google cloud project name in the format: "projects/abc" or "projects/123". As input, project name with either project id or number are accepted. As output, this field will contain project number.

string gcp_project = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... }

Returns
Type Description
String

The gcpProject.

getGcpProjectBytes()

public ByteString getGcpProjectBytes()

Required. Immutable. Google cloud project name in the format: "projects/abc" or "projects/123". As input, project name with either project id or number are accepted. As output, this field will contain project number.

string gcp_project = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... }

Returns
Type Description
ByteString

The bytes for gcpProject.

getName()

public String getName()

Identifier. The name of the host project registration. Format: "projects/{project}/locations/{location}/hostProjectRegistrations/{host_project_registration}".

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

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Identifier. The name of the host project registration. Format: "projects/{project}/locations/{location}/hostProjectRegistrations/{host_project_registration}".

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

Returns
Type Description
ByteString

The bytes for name.

hasCreateTime()

public boolean hasCreateTime()

Output only. The time at which the host project registration was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the createTime field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeCreateTime(Timestamp value)

public HostProjectRegistration.Builder mergeCreateTime(Timestamp value)

Output only. The time at which the host project registration was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
HostProjectRegistration.Builder

mergeFrom(HostProjectRegistration other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

public final HostProjectRegistration.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
HostProjectRegistration.Builder
Overrides

setCreateTime(Timestamp value)

public HostProjectRegistration.Builder setCreateTime(Timestamp value)

Output only. The time at which the host project registration was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
HostProjectRegistration.Builder

setCreateTime(Timestamp.Builder builderForValue)

public HostProjectRegistration.Builder setCreateTime(Timestamp.Builder builderForValue)

Output only. The time at which the host project registration was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
HostProjectRegistration.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public HostProjectRegistration.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
HostProjectRegistration.Builder
Overrides

setGcpProject(String value)

public HostProjectRegistration.Builder setGcpProject(String value)

Required. Immutable. Google cloud project name in the format: "projects/abc" or "projects/123". As input, project name with either project id or number are accepted. As output, this field will contain project number.

string gcp_project = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The gcpProject to set.

Returns
Type Description
HostProjectRegistration.Builder

This builder for chaining.

setGcpProjectBytes(ByteString value)

public HostProjectRegistration.Builder setGcpProjectBytes(ByteString value)

Required. Immutable. Google cloud project name in the format: "projects/abc" or "projects/123". As input, project name with either project id or number are accepted. As output, this field will contain project number.

string gcp_project = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes for gcpProject to set.

Returns
Type Description
HostProjectRegistration.Builder

This builder for chaining.

setName(String value)

public HostProjectRegistration.Builder setName(String value)

Identifier. The name of the host project registration. Format: "projects/{project}/locations/{location}/hostProjectRegistrations/{host_project_registration}".

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

Parameter
Name Description
value String

The name to set.

Returns
Type Description
HostProjectRegistration.Builder

This builder for chaining.

setNameBytes(ByteString value)

public HostProjectRegistration.Builder setNameBytes(ByteString value)

Identifier. The name of the host project registration. Format: "projects/{project}/locations/{location}/hostProjectRegistrations/{host_project_registration}".

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

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
HostProjectRegistration.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public HostProjectRegistration.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
HostProjectRegistration.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final HostProjectRegistration.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
HostProjectRegistration.Builder
Overrides