TextSource Class

public final class TextSource
extends PlaySource

The FileSource model.

Constructor Summary

Constructor Description
TextSource()

Creates a new instance of TextSource.

Method Summary

Modifier and Type Method and Description
static TextSource fromJson(JsonReader jsonReader)

Reads an instance of TextSource from the JsonReader.

String getCustomVoiceEndpointId()

Get the customVoiceEndpointId property: Endpoint where the custom voice was deployed.

String getSourceLocale()

Get the sourceLocale property: Source language locale to be played.

String getText()

Get the text property: Text for the cognitive service to be played.

VoiceKind getVoiceKind()

Get the voiceKind property: Voice kind type.

String getVoiceName()

Get the voiceName property: Voice name to be played.

TextSource setCustomVoiceEndpointId(String customVoiceEndpointId)

Set the customVoiceEndpointId property: Endpoint where the custom voice was deployed.

TextSource setSourceLocale(String sourceLocale)

Set the sourceLocale property: Source language locale to be played.

TextSource setText(String text)

Set the text property: Text for the cognitive service to be played.

TextSource setVoiceKind(VoiceKind voiceKind)

Set the voiceKind property: Voice kind type.

TextSource setVoiceName(String voiceName)

Set the voiceName property: Voice name to be played.

JsonWriter toJson(JsonWriter jsonWriter)

Methods inherited from PlaySource

Methods inherited from java.lang.Object

Constructor Details

TextSource

public TextSource()

Creates a new instance of TextSource.

Method Details

fromJson

public static TextSource fromJson(JsonReader jsonReader)

Reads an instance of TextSource from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of TextSource if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If an error occurs while reading the TextSource.

getCustomVoiceEndpointId

public String getCustomVoiceEndpointId()

Get the customVoiceEndpointId property: Endpoint where the custom voice was deployed.

Returns:

the customVoiceEndpointId value.

getSourceLocale

public String getSourceLocale()

Get the sourceLocale property: Source language locale to be played.

Returns:

the sourceLocale value.

getText

public String getText()

Get the text property: Text for the cognitive service to be played.

Returns:

the text value.

getVoiceKind

public VoiceKind getVoiceKind()

Get the voiceKind property: Voice kind type.

Returns:

the voiceKind value.

getVoiceName

public String getVoiceName()

Get the voiceName property: Voice name to be played.

Returns:

the voiceName value.

setCustomVoiceEndpointId

public TextSource setCustomVoiceEndpointId(String customVoiceEndpointId)

Set the customVoiceEndpointId property: Endpoint where the custom voice was deployed.

Parameters:

customVoiceEndpointId - the customVoiceEndpointId value to set.

Returns:

the TextSourceInternal object itself.

setSourceLocale

public TextSource setSourceLocale(String sourceLocale)

Set the sourceLocale property: Source language locale to be played.

Parameters:

sourceLocale - the sourceLocale value to set.

Returns:

the TextSource object itself.

setText

public TextSource setText(String text)

Set the text property: Text for the cognitive service to be played.

Parameters:

text - the text value to set.

Returns:

the TextSource object itself.

setVoiceKind

public TextSource setVoiceKind(VoiceKind voiceKind)

Set the voiceKind property: Voice kind type.

Parameters:

voiceKind - the voiceKind value to set.

Returns:

the TextSource object itself.

setVoiceName

public TextSource setVoiceName(String voiceName)

Set the voiceName property: Voice name to be played.

Parameters:

voiceName - the voiceName value to set.

Returns:

the TextSourceInternal object itself.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

Applies to