Class AdvancedVoiceOptions.Builder (2.92.0)

public static final class AdvancedVoiceOptions.Builder extends GeneratedMessage.Builder<AdvancedVoiceOptions.Builder> implements AdvancedVoiceOptionsOrBuilder

Used for advanced voice options.

Protobuf type google.cloud.texttospeech.v1.AdvancedVoiceOptions

Static Methods

getDescriptor()

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

Methods

build()

public AdvancedVoiceOptions build()
Returns
Type Description
AdvancedVoiceOptions

buildPartial()

public AdvancedVoiceOptions buildPartial()
Returns
Type Description
AdvancedVoiceOptions

clear()

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

clearEnableTextnorm()

public AdvancedVoiceOptions.Builder clearEnableTextnorm()

Optional. If true, textnorm will be applied to text input. This feature is enabled by default. Only applies for Gemini TTS.

optional bool enable_textnorm = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AdvancedVoiceOptions.Builder

This builder for chaining.

clearLowLatencyJourneySynthesis()

public AdvancedVoiceOptions.Builder clearLowLatencyJourneySynthesis()

Only for Journey voices. If false, the synthesis is context aware and has a higher latency.

optional bool low_latency_journey_synthesis = 1;

Returns
Type Description
AdvancedVoiceOptions.Builder

This builder for chaining.

clearRelaxSafetyFilters() (deprecated)

public AdvancedVoiceOptions.Builder clearRelaxSafetyFilters()

Deprecated. google.cloud.texttospeech.v1.AdvancedVoiceOptions.relax_safety_filters is deprecated. See google/cloud/texttospeech/v1/cloud_tts.proto;l=224

Optional. Input only. Deprecated, use safety_settings instead. If true, relaxes safety filters for Gemini TTS.

bool relax_safety_filters = 8 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AdvancedVoiceOptions.Builder

This builder for chaining.

clearSafetySettings()

public AdvancedVoiceOptions.Builder clearSafetySettings()

Optional. Input only. This applies to Gemini TTS only. If set, the category specified in the safety setting will be blocked if the harm probability is above the threshold. Otherwise, the safety filter will be disabled by default.

.google.cloud.texttospeech.v1.AdvancedVoiceOptions.SafetySettings safety_settings = 9 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AdvancedVoiceOptions.Builder

getDefaultInstanceForType()

public AdvancedVoiceOptions getDefaultInstanceForType()
Returns
Type Description
AdvancedVoiceOptions

getDescriptorForType()

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

getEnableTextnorm()

public boolean getEnableTextnorm()

Optional. If true, textnorm will be applied to text input. This feature is enabled by default. Only applies for Gemini TTS.

optional bool enable_textnorm = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

The enableTextnorm.

getLowLatencyJourneySynthesis()

public boolean getLowLatencyJourneySynthesis()

Only for Journey voices. If false, the synthesis is context aware and has a higher latency.

optional bool low_latency_journey_synthesis = 1;

Returns
Type Description
boolean

The lowLatencyJourneySynthesis.

getRelaxSafetyFilters() (deprecated)

public boolean getRelaxSafetyFilters()

Deprecated. google.cloud.texttospeech.v1.AdvancedVoiceOptions.relax_safety_filters is deprecated. See google/cloud/texttospeech/v1/cloud_tts.proto;l=224

Optional. Input only. Deprecated, use safety_settings instead. If true, relaxes safety filters for Gemini TTS.

bool relax_safety_filters = 8 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

The relaxSafetyFilters.

getSafetySettings()

public AdvancedVoiceOptions.SafetySettings getSafetySettings()

Optional. Input only. This applies to Gemini TTS only. If set, the category specified in the safety setting will be blocked if the harm probability is above the threshold. Otherwise, the safety filter will be disabled by default.

.google.cloud.texttospeech.v1.AdvancedVoiceOptions.SafetySettings safety_settings = 9 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AdvancedVoiceOptions.SafetySettings

The safetySettings.

getSafetySettingsBuilder()

public AdvancedVoiceOptions.SafetySettings.Builder getSafetySettingsBuilder()

Optional. Input only. This applies to Gemini TTS only. If set, the category specified in the safety setting will be blocked if the harm probability is above the threshold. Otherwise, the safety filter will be disabled by default.

.google.cloud.texttospeech.v1.AdvancedVoiceOptions.SafetySettings safety_settings = 9 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AdvancedVoiceOptions.SafetySettings.Builder

getSafetySettingsOrBuilder()

public AdvancedVoiceOptions.SafetySettingsOrBuilder getSafetySettingsOrBuilder()

Optional. Input only. This applies to Gemini TTS only. If set, the category specified in the safety setting will be blocked if the harm probability is above the threshold. Otherwise, the safety filter will be disabled by default.

.google.cloud.texttospeech.v1.AdvancedVoiceOptions.SafetySettings safety_settings = 9 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AdvancedVoiceOptions.SafetySettingsOrBuilder

hasEnableTextnorm()

public boolean hasEnableTextnorm()

Optional. If true, textnorm will be applied to text input. This feature is enabled by default. Only applies for Gemini TTS.

optional bool enable_textnorm = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the enableTextnorm field is set.

hasLowLatencyJourneySynthesis()

public boolean hasLowLatencyJourneySynthesis()

Only for Journey voices. If false, the synthesis is context aware and has a higher latency.

optional bool low_latency_journey_synthesis = 1;

Returns
Type Description
boolean

Whether the lowLatencyJourneySynthesis field is set.

hasSafetySettings()

public boolean hasSafetySettings()

Optional. Input only. This applies to Gemini TTS only. If set, the category specified in the safety setting will be blocked if the harm probability is above the threshold. Otherwise, the safety filter will be disabled by default.

.google.cloud.texttospeech.v1.AdvancedVoiceOptions.SafetySettings safety_settings = 9 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the safetySettings field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(AdvancedVoiceOptions other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeSafetySettings(AdvancedVoiceOptions.SafetySettings value)

public AdvancedVoiceOptions.Builder mergeSafetySettings(AdvancedVoiceOptions.SafetySettings value)

Optional. Input only. This applies to Gemini TTS only. If set, the category specified in the safety setting will be blocked if the harm probability is above the threshold. Otherwise, the safety filter will be disabled by default.

.google.cloud.texttospeech.v1.AdvancedVoiceOptions.SafetySettings safety_settings = 9 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value AdvancedVoiceOptions.SafetySettings
Returns
Type Description
AdvancedVoiceOptions.Builder

setEnableTextnorm(boolean value)

public AdvancedVoiceOptions.Builder setEnableTextnorm(boolean value)

Optional. If true, textnorm will be applied to text input. This feature is enabled by default. Only applies for Gemini TTS.

optional bool enable_textnorm = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value boolean

The enableTextnorm to set.

Returns
Type Description
AdvancedVoiceOptions.Builder

This builder for chaining.

setLowLatencyJourneySynthesis(boolean value)

public AdvancedVoiceOptions.Builder setLowLatencyJourneySynthesis(boolean value)

Only for Journey voices. If false, the synthesis is context aware and has a higher latency.

optional bool low_latency_journey_synthesis = 1;

Parameter
Name Description
value boolean

The lowLatencyJourneySynthesis to set.

Returns
Type Description
AdvancedVoiceOptions.Builder

This builder for chaining.

setRelaxSafetyFilters(boolean value) (deprecated)

public AdvancedVoiceOptions.Builder setRelaxSafetyFilters(boolean value)

Deprecated. google.cloud.texttospeech.v1.AdvancedVoiceOptions.relax_safety_filters is deprecated. See google/cloud/texttospeech/v1/cloud_tts.proto;l=224

Optional. Input only. Deprecated, use safety_settings instead. If true, relaxes safety filters for Gemini TTS.

bool relax_safety_filters = 8 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value boolean

The relaxSafetyFilters to set.

Returns
Type Description
AdvancedVoiceOptions.Builder

This builder for chaining.

setSafetySettings(AdvancedVoiceOptions.SafetySettings value)

public AdvancedVoiceOptions.Builder setSafetySettings(AdvancedVoiceOptions.SafetySettings value)

Optional. Input only. This applies to Gemini TTS only. If set, the category specified in the safety setting will be blocked if the harm probability is above the threshold. Otherwise, the safety filter will be disabled by default.

.google.cloud.texttospeech.v1.AdvancedVoiceOptions.SafetySettings safety_settings = 9 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value AdvancedVoiceOptions.SafetySettings
Returns
Type Description
AdvancedVoiceOptions.Builder

setSafetySettings(AdvancedVoiceOptions.SafetySettings.Builder builderForValue)

public AdvancedVoiceOptions.Builder setSafetySettings(AdvancedVoiceOptions.SafetySettings.Builder builderForValue)

Optional. Input only. This applies to Gemini TTS only. If set, the category specified in the safety setting will be blocked if the harm probability is above the threshold. Otherwise, the safety filter will be disabled by default.

.google.cloud.texttospeech.v1.AdvancedVoiceOptions.SafetySettings safety_settings = 9 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue AdvancedVoiceOptions.SafetySettings.Builder
Returns
Type Description
AdvancedVoiceOptions.Builder