Class CustomClass.Builder (2.5.0)

public static final class CustomClass.Builder extends GeneratedMessageV3.Builder<CustomClass.Builder> implements CustomClassOrBuilder

A set of words or phrases that represents a common concept likely to appear in your audio, for example a list of passenger ship names. CustomClass items can be substituted into placeholders that you set in PhraseSet phrases.

Protobuf type google.cloud.speech.v1.CustomClass

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addAllItems(Iterable<? extends CustomClass.ClassItem> values)

public CustomClass.Builder addAllItems(Iterable<? extends CustomClass.ClassItem> values)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameter
NameDescription
valuesIterable<? extends com.google.cloud.speech.v1.CustomClass.ClassItem>
Returns
TypeDescription
CustomClass.Builder

addItems(CustomClass.ClassItem value)

public CustomClass.Builder addItems(CustomClass.ClassItem value)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameter
NameDescription
valueCustomClass.ClassItem
Returns
TypeDescription
CustomClass.Builder

addItems(CustomClass.ClassItem.Builder builderForValue)

public CustomClass.Builder addItems(CustomClass.ClassItem.Builder builderForValue)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameter
NameDescription
builderForValueCustomClass.ClassItem.Builder
Returns
TypeDescription
CustomClass.Builder

addItems(int index, CustomClass.ClassItem value)

public CustomClass.Builder addItems(int index, CustomClass.ClassItem value)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameters
NameDescription
indexint
valueCustomClass.ClassItem
Returns
TypeDescription
CustomClass.Builder

addItems(int index, CustomClass.ClassItem.Builder builderForValue)

public CustomClass.Builder addItems(int index, CustomClass.ClassItem.Builder builderForValue)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameters
NameDescription
indexint
builderForValueCustomClass.ClassItem.Builder
Returns
TypeDescription
CustomClass.Builder

addItemsBuilder()

public CustomClass.ClassItem.Builder addItemsBuilder()

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Returns
TypeDescription
CustomClass.ClassItem.Builder

addItemsBuilder(int index)

public CustomClass.ClassItem.Builder addItemsBuilder(int index)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameter
NameDescription
indexint
Returns
TypeDescription
CustomClass.ClassItem.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public CustomClass.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
CustomClass.Builder
Overrides

build()

public CustomClass build()
Returns
TypeDescription
CustomClass

buildPartial()

public CustomClass buildPartial()
Returns
TypeDescription
CustomClass

clear()

public CustomClass.Builder clear()
Returns
TypeDescription
CustomClass.Builder
Overrides

clearCustomClassId()

public CustomClass.Builder clearCustomClassId()

If this custom class is a resource, the custom_class_id is the resource id of the CustomClass. Case sensitive.

string custom_class_id = 2;

Returns
TypeDescription
CustomClass.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public CustomClass.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
CustomClass.Builder
Overrides

clearItems()

public CustomClass.Builder clearItems()

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Returns
TypeDescription
CustomClass.Builder

clearName()

public CustomClass.Builder clearName()

The resource name of the custom class.

string name = 1;

Returns
TypeDescription
CustomClass.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public CustomClass.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
CustomClass.Builder
Overrides

clone()

public CustomClass.Builder clone()
Returns
TypeDescription
CustomClass.Builder
Overrides

getCustomClassId()

public String getCustomClassId()

If this custom class is a resource, the custom_class_id is the resource id of the CustomClass. Case sensitive.

string custom_class_id = 2;

Returns
TypeDescription
String

The customClassId.

getCustomClassIdBytes()

public ByteString getCustomClassIdBytes()

If this custom class is a resource, the custom_class_id is the resource id of the CustomClass. Case sensitive.

string custom_class_id = 2;

Returns
TypeDescription
ByteString

The bytes for customClassId.

getDefaultInstanceForType()

public CustomClass getDefaultInstanceForType()
Returns
TypeDescription
CustomClass

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getItems(int index)

public CustomClass.ClassItem getItems(int index)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameter
NameDescription
indexint
Returns
TypeDescription
CustomClass.ClassItem

getItemsBuilder(int index)

public CustomClass.ClassItem.Builder getItemsBuilder(int index)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameter
NameDescription
indexint
Returns
TypeDescription
CustomClass.ClassItem.Builder

getItemsBuilderList()

public List<CustomClass.ClassItem.Builder> getItemsBuilderList()

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Returns
TypeDescription
List<Builder>

getItemsCount()

public int getItemsCount()

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Returns
TypeDescription
int

getItemsList()

public List<CustomClass.ClassItem> getItemsList()

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Returns
TypeDescription
List<ClassItem>

getItemsOrBuilder(int index)

public CustomClass.ClassItemOrBuilder getItemsOrBuilder(int index)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameter
NameDescription
indexint
Returns
TypeDescription
CustomClass.ClassItemOrBuilder

getItemsOrBuilderList()

public List<? extends CustomClass.ClassItemOrBuilder> getItemsOrBuilderList()

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Returns
TypeDescription
List<? extends com.google.cloud.speech.v1.CustomClass.ClassItemOrBuilder>

getName()

public String getName()

The resource name of the custom class.

string name = 1;

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

The resource name of the custom class.

string name = 1;

Returns
TypeDescription
ByteString

The bytes for name.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(CustomClass other)

public CustomClass.Builder mergeFrom(CustomClass other)
Parameter
NameDescription
otherCustomClass
Returns
TypeDescription
CustomClass.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public CustomClass.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
CustomClass.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public CustomClass.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
CustomClass.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final CustomClass.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
CustomClass.Builder
Overrides

removeItems(int index)

public CustomClass.Builder removeItems(int index)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameter
NameDescription
indexint
Returns
TypeDescription
CustomClass.Builder

setCustomClassId(String value)

public CustomClass.Builder setCustomClassId(String value)

If this custom class is a resource, the custom_class_id is the resource id of the CustomClass. Case sensitive.

string custom_class_id = 2;

Parameter
NameDescription
valueString

The customClassId to set.

Returns
TypeDescription
CustomClass.Builder

This builder for chaining.

setCustomClassIdBytes(ByteString value)

public CustomClass.Builder setCustomClassIdBytes(ByteString value)

If this custom class is a resource, the custom_class_id is the resource id of the CustomClass. Case sensitive.

string custom_class_id = 2;

Parameter
NameDescription
valueByteString

The bytes for customClassId to set.

Returns
TypeDescription
CustomClass.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public CustomClass.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
CustomClass.Builder
Overrides

setItems(int index, CustomClass.ClassItem value)

public CustomClass.Builder setItems(int index, CustomClass.ClassItem value)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameters
NameDescription
indexint
valueCustomClass.ClassItem
Returns
TypeDescription
CustomClass.Builder

setItems(int index, CustomClass.ClassItem.Builder builderForValue)

public CustomClass.Builder setItems(int index, CustomClass.ClassItem.Builder builderForValue)

A collection of class items.

repeated .google.cloud.speech.v1.CustomClass.ClassItem items = 3;

Parameters
NameDescription
indexint
builderForValueCustomClass.ClassItem.Builder
Returns
TypeDescription
CustomClass.Builder

setName(String value)

public CustomClass.Builder setName(String value)

The resource name of the custom class.

string name = 1;

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
CustomClass.Builder

This builder for chaining.

setNameBytes(ByteString value)

public CustomClass.Builder setNameBytes(ByteString value)

The resource name of the custom class.

string name = 1;

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
CustomClass.Builder

This builder for chaining.

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

public CustomClass.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
CustomClass.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final CustomClass.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
CustomClass.Builder
Overrides