Class SpeakerDiarizationConfig.Builder (2.5.1)

public static final class SpeakerDiarizationConfig.Builder extends GeneratedMessageV3.Builder<SpeakerDiarizationConfig.Builder> implements SpeakerDiarizationConfigOrBuilder

Config to enable speaker diarization.

Protobuf type google.cloud.speech.v1.SpeakerDiarizationConfig

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public SpeakerDiarizationConfig build()
Returns
TypeDescription
SpeakerDiarizationConfig

buildPartial()

public SpeakerDiarizationConfig buildPartial()
Returns
TypeDescription
SpeakerDiarizationConfig

clear()

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

clearEnableSpeakerDiarization()

public SpeakerDiarizationConfig.Builder clearEnableSpeakerDiarization()

If 'true', enables speaker detection for each recognized word in the top alternative of the recognition result using a speaker_tag provided in the WordInfo.

bool enable_speaker_diarization = 1;

Returns
TypeDescription
SpeakerDiarizationConfig.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearMaxSpeakerCount()

public SpeakerDiarizationConfig.Builder clearMaxSpeakerCount()

Maximum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 6.

int32 max_speaker_count = 3;

Returns
TypeDescription
SpeakerDiarizationConfig.Builder

This builder for chaining.

clearMinSpeakerCount()

public SpeakerDiarizationConfig.Builder clearMinSpeakerCount()

Minimum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 2.

int32 min_speaker_count = 2;

Returns
TypeDescription
SpeakerDiarizationConfig.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearSpeakerTag() (deprecated)

public SpeakerDiarizationConfig.Builder clearSpeakerTag()

Deprecated. google.cloud.speech.v1.SpeakerDiarizationConfig.speaker_tag is deprecated. See google/cloud/speech/v1/cloud_speech.proto;l=457

Output only. Unused.

int32 speaker_tag = 5 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
SpeakerDiarizationConfig.Builder

This builder for chaining.

clone()

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

getDefaultInstanceForType()

public SpeakerDiarizationConfig getDefaultInstanceForType()
Returns
TypeDescription
SpeakerDiarizationConfig

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getEnableSpeakerDiarization()

public boolean getEnableSpeakerDiarization()

If 'true', enables speaker detection for each recognized word in the top alternative of the recognition result using a speaker_tag provided in the WordInfo.

bool enable_speaker_diarization = 1;

Returns
TypeDescription
boolean

The enableSpeakerDiarization.

getMaxSpeakerCount()

public int getMaxSpeakerCount()

Maximum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 6.

int32 max_speaker_count = 3;

Returns
TypeDescription
int

The maxSpeakerCount.

getMinSpeakerCount()

public int getMinSpeakerCount()

Minimum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 2.

int32 min_speaker_count = 2;

Returns
TypeDescription
int

The minSpeakerCount.

getSpeakerTag() (deprecated)

public int getSpeakerTag()

Deprecated. google.cloud.speech.v1.SpeakerDiarizationConfig.speaker_tag is deprecated. See google/cloud/speech/v1/cloud_speech.proto;l=457

Output only. Unused.

int32 speaker_tag = 5 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
int

The speakerTag.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(SpeakerDiarizationConfig other)

public SpeakerDiarizationConfig.Builder mergeFrom(SpeakerDiarizationConfig other)
Parameter
NameDescription
otherSpeakerDiarizationConfig
Returns
TypeDescription
SpeakerDiarizationConfig.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setEnableSpeakerDiarization(boolean value)

public SpeakerDiarizationConfig.Builder setEnableSpeakerDiarization(boolean value)

If 'true', enables speaker detection for each recognized word in the top alternative of the recognition result using a speaker_tag provided in the WordInfo.

bool enable_speaker_diarization = 1;

Parameter
NameDescription
valueboolean

The enableSpeakerDiarization to set.

Returns
TypeDescription
SpeakerDiarizationConfig.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

setMaxSpeakerCount(int value)

public SpeakerDiarizationConfig.Builder setMaxSpeakerCount(int value)

Maximum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 6.

int32 max_speaker_count = 3;

Parameter
NameDescription
valueint

The maxSpeakerCount to set.

Returns
TypeDescription
SpeakerDiarizationConfig.Builder

This builder for chaining.

setMinSpeakerCount(int value)

public SpeakerDiarizationConfig.Builder setMinSpeakerCount(int value)

Minimum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 2.

int32 min_speaker_count = 2;

Parameter
NameDescription
valueint

The minSpeakerCount to set.

Returns
TypeDescription
SpeakerDiarizationConfig.Builder

This builder for chaining.

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

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

setSpeakerTag(int value) (deprecated)

public SpeakerDiarizationConfig.Builder setSpeakerTag(int value)

Deprecated. google.cloud.speech.v1.SpeakerDiarizationConfig.speaker_tag is deprecated. See google/cloud/speech/v1/cloud_speech.proto;l=457

Output only. Unused.

int32 speaker_tag = 5 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueint

The speakerTag to set.

Returns
TypeDescription
SpeakerDiarizationConfig.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

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