Package com.google.genai.types
Class ReplicatedVoiceConfig
-
- All Implemented Interfaces:
public abstract class ReplicatedVoiceConfig extends JsonSerializable
The configuration for the replicated voice to use.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public abstract classReplicatedVoiceConfig.BuilderBuilder for ReplicatedVoiceConfig.
-
Field Summary
Fields Modifier and Type Field Description public final static StringMAX_READ_LENGTH_PROPERTY
-
Constructor Summary
Constructors Constructor Description ReplicatedVoiceConfig()
-
Method Summary
Modifier and Type Method Description abstract Optional<String>mimeType()The mimetype of the voice sample. abstract Optional<Array<byte>>voiceSampleAudio()The sample of the custom voice. static ReplicatedVoiceConfig.Builderbuilder()Instantiates a builder for ReplicatedVoiceConfig. abstract ReplicatedVoiceConfig.BuildertoBuilder()Creates a builder with the same values as this instance. static ReplicatedVoiceConfigfromJson(String jsonString)Deserializes a JSON string to a ReplicatedVoiceConfig object. -
Methods inherited from class com.google.genai.JsonSerializable
fromJsonNode, fromJsonString, objectMapper, setMaxReadLength, stringToJsonNode, toJson, toJsonNode, toJsonString -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
mimeType
abstract Optional<String> mimeType()
The mimetype of the voice sample. The only currently supported value is `audio/wav`. This represents 16-bit signed little-endian wav data, with a 24kHz sampling rate.
-
voiceSampleAudio
abstract Optional<Array<byte>> voiceSampleAudio()
The sample of the custom voice.
-
builder
static ReplicatedVoiceConfig.Builder builder()
Instantiates a builder for ReplicatedVoiceConfig.
-
toBuilder
abstract ReplicatedVoiceConfig.Builder toBuilder()
Creates a builder with the same values as this instance.
-
fromJson
static ReplicatedVoiceConfig fromJson(String jsonString)
Deserializes a JSON string to a ReplicatedVoiceConfig object.
-
-
-
-