Class ServiceClass.Builder (1.61.0)

public static final class ServiceClass.Builder extends GeneratedMessageV3.Builder<ServiceClass.Builder> implements ServiceClassOrBuilder

The ServiceClass resource.

Protobuf type google.cloud.networkconnectivity.v1.ServiceClass

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public ServiceClass build()
Returns
Type Description
ServiceClass

buildPartial()

public ServiceClass buildPartial()
Returns
Type Description
ServiceClass

clear()

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

clearCreateTime()

public ServiceClass.Builder clearCreateTime()

Output only. Time when the ServiceClass was created.

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

Returns
Type Description
ServiceClass.Builder

clearDescription()

public ServiceClass.Builder clearDescription()

A description of this resource.

string description = 5;

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

clearEtag()

public ServiceClass.Builder clearEtag()

Optional. The etag is computed by the server, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

optional string etag = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearLabels()

public ServiceClass.Builder clearLabels()
Returns
Type Description
ServiceClass.Builder

clearName()

public ServiceClass.Builder clearName()

Immutable. The name of a ServiceClass resource. Format: projects/{project}/locations/{location}/serviceClasses/{service_class} See: https://google.aip.dev/122#fields-representing-resource-names

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

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearServiceClass()

public ServiceClass.Builder clearServiceClass()

Output only. The generated service class name. Use this name to refer to the Service class in Service Connection Maps and Service Connection Policies.

string service_class = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

clearUpdateTime()

public ServiceClass.Builder clearUpdateTime()

Output only. Time when the ServiceClass was updated.

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

Returns
Type Description
ServiceClass.Builder

clone()

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

containsLabels(String key)

public boolean containsLabels(String key)

User-defined labels.

map<string, string> labels = 4;

Parameter
Name Description
key String
Returns
Type Description
boolean

getCreateTime()

public Timestamp getCreateTime()

Output only. Time when the ServiceClass was created.

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

Returns
Type Description
Timestamp

The createTime.

getCreateTimeBuilder()

public Timestamp.Builder getCreateTimeBuilder()

Output only. Time when the ServiceClass was created.

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

Returns
Type Description
Builder

getCreateTimeOrBuilder()

public TimestampOrBuilder getCreateTimeOrBuilder()

Output only. Time when the ServiceClass was created.

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

Returns
Type Description
TimestampOrBuilder

getDefaultInstanceForType()

public ServiceClass getDefaultInstanceForType()
Returns
Type Description
ServiceClass

getDescription()

public String getDescription()

A description of this resource.

string description = 5;

Returns
Type Description
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

A description of this resource.

string description = 5;

Returns
Type Description
ByteString

The bytes for description.

getDescriptorForType()

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

getEtag()

public String getEtag()

Optional. The etag is computed by the server, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

optional string etag = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The etag.

getEtagBytes()

public ByteString getEtagBytes()

Optional. The etag is computed by the server, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

optional string etag = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for etag.

getLabels() (deprecated)

public Map<String,String> getLabels()

Use #getLabelsMap() instead.

Returns
Type Description
Map<String,String>

getLabelsCount()

public int getLabelsCount()

User-defined labels.

map<string, string> labels = 4;

Returns
Type Description
int

getLabelsMap()

public Map<String,String> getLabelsMap()

User-defined labels.

map<string, string> labels = 4;

Returns
Type Description
Map<String,String>

getLabelsOrDefault(String key, String defaultValue)

public String getLabelsOrDefault(String key, String defaultValue)

User-defined labels.

map<string, string> labels = 4;

Parameters
Name Description
key String
defaultValue String
Returns
Type Description
String

getLabelsOrThrow(String key)

public String getLabelsOrThrow(String key)

User-defined labels.

map<string, string> labels = 4;

Parameter
Name Description
key String
Returns
Type Description
String

getMutableLabels() (deprecated)

public Map<String,String> getMutableLabels()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,String>

getName()

public String getName()

Immutable. The name of a ServiceClass resource. Format: projects/{project}/locations/{location}/serviceClasses/{service_class} See: https://google.aip.dev/122#fields-representing-resource-names

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

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Immutable. The name of a ServiceClass resource. Format: projects/{project}/locations/{location}/serviceClasses/{service_class} See: https://google.aip.dev/122#fields-representing-resource-names

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

Returns
Type Description
ByteString

The bytes for name.

getServiceClass()

public String getServiceClass()

Output only. The generated service class name. Use this name to refer to the Service class in Service Connection Maps and Service Connection Policies.

string service_class = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
String

The serviceClass.

getServiceClassBytes()

public ByteString getServiceClassBytes()

Output only. The generated service class name. Use this name to refer to the Service class in Service Connection Maps and Service Connection Policies.

string service_class = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ByteString

The bytes for serviceClass.

getUpdateTime()

public Timestamp getUpdateTime()

Output only. Time when the ServiceClass was updated.

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

Returns
Type Description
Timestamp

The updateTime.

getUpdateTimeBuilder()

public Timestamp.Builder getUpdateTimeBuilder()

Output only. Time when the ServiceClass was updated.

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

Returns
Type Description
Builder

getUpdateTimeOrBuilder()

public TimestampOrBuilder getUpdateTimeOrBuilder()

Output only. Time when the ServiceClass was updated.

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

Returns
Type Description
TimestampOrBuilder

hasCreateTime()

public boolean hasCreateTime()

Output only. Time when the ServiceClass was created.

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

Returns
Type Description
boolean

Whether the createTime field is set.

hasEtag()

public boolean hasEtag()

Optional. The etag is computed by the server, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

optional string etag = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the etag field is set.

hasUpdateTime()

public boolean hasUpdateTime()

Output only. Time when the ServiceClass was updated.

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

Returns
Type Description
boolean

Whether the updateTime field is set.

internalGetFieldAccessorTable()

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

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeCreateTime(Timestamp value)

public ServiceClass.Builder mergeCreateTime(Timestamp value)

Output only. Time when the ServiceClass was created.

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

Parameter
Name Description
value Timestamp
Returns
Type Description
ServiceClass.Builder

mergeFrom(ServiceClass other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

mergeUpdateTime(Timestamp value)

public ServiceClass.Builder mergeUpdateTime(Timestamp value)

Output only. Time when the ServiceClass was updated.

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

Parameter
Name Description
value Timestamp
Returns
Type Description
ServiceClass.Builder

putAllLabels(Map<String,String> values)

public ServiceClass.Builder putAllLabels(Map<String,String> values)

User-defined labels.

map<string, string> labels = 4;

Parameter
Name Description
values Map<String,String>
Returns
Type Description
ServiceClass.Builder

putLabels(String key, String value)

public ServiceClass.Builder putLabels(String key, String value)

User-defined labels.

map<string, string> labels = 4;

Parameters
Name Description
key String
value String
Returns
Type Description
ServiceClass.Builder

removeLabels(String key)

public ServiceClass.Builder removeLabels(String key)

User-defined labels.

map<string, string> labels = 4;

Parameter
Name Description
key String
Returns
Type Description
ServiceClass.Builder

setCreateTime(Timestamp value)

public ServiceClass.Builder setCreateTime(Timestamp value)

Output only. Time when the ServiceClass was created.

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

Parameter
Name Description
value Timestamp
Returns
Type Description
ServiceClass.Builder

setCreateTime(Timestamp.Builder builderForValue)

public ServiceClass.Builder setCreateTime(Timestamp.Builder builderForValue)

Output only. Time when the ServiceClass was created.

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

Parameter
Name Description
builderForValue Builder
Returns
Type Description
ServiceClass.Builder

setDescription(String value)

public ServiceClass.Builder setDescription(String value)

A description of this resource.

string description = 5;

Parameter
Name Description
value String

The description to set.

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

setDescriptionBytes(ByteString value)

public ServiceClass.Builder setDescriptionBytes(ByteString value)

A description of this resource.

string description = 5;

Parameter
Name Description
value ByteString

The bytes for description to set.

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

setEtag(String value)

public ServiceClass.Builder setEtag(String value)

Optional. The etag is computed by the server, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

optional string etag = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The etag to set.

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

setEtagBytes(ByteString value)

public ServiceClass.Builder setEtagBytes(ByteString value)

Optional. The etag is computed by the server, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

optional string etag = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for etag to set.

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

setName(String value)

public ServiceClass.Builder setName(String value)

Immutable. The name of a ServiceClass resource. Format: projects/{project}/locations/{location}/serviceClasses/{service_class} See: https://google.aip.dev/122#fields-representing-resource-names

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

Parameter
Name Description
value String

The name to set.

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

setNameBytes(ByteString value)

public ServiceClass.Builder setNameBytes(ByteString value)

Immutable. The name of a ServiceClass resource. Format: projects/{project}/locations/{location}/serviceClasses/{service_class} See: https://google.aip.dev/122#fields-representing-resource-names

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

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

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

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

setServiceClass(String value)

public ServiceClass.Builder setServiceClass(String value)

Output only. The generated service class name. Use this name to refer to the Service class in Service Connection Maps and Service Connection Policies.

string service_class = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value String

The serviceClass to set.

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

setServiceClassBytes(ByteString value)

public ServiceClass.Builder setServiceClassBytes(ByteString value)

Output only. The generated service class name. Use this name to refer to the Service class in Service Connection Maps and Service Connection Policies.

string service_class = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value ByteString

The bytes for serviceClass to set.

Returns
Type Description
ServiceClass.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

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

setUpdateTime(Timestamp value)

public ServiceClass.Builder setUpdateTime(Timestamp value)

Output only. Time when the ServiceClass was updated.

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

Parameter
Name Description
value Timestamp
Returns
Type Description
ServiceClass.Builder

setUpdateTime(Timestamp.Builder builderForValue)

public ServiceClass.Builder setUpdateTime(Timestamp.Builder builderForValue)

Output only. Time when the ServiceClass was updated.

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

Parameter
Name Description
builderForValue Builder
Returns
Type Description
ServiceClass.Builder