Home > @magiclane/maps-sdk > TtsLocalizationService > getStrings
TtsLocalizationService.getStrings() method
Retrieves multiple localized TTS strings for the given list of string IDs.
If useDefaultString is true and a string ID is not available for the currently selected TTS voice/language, the default string (English) will be returned instead of an empty string. If a string ID does not exist, an empty string is returned for that ID.
Signature:
static getStrings(stringIds: number[], useDefaultString?: boolean): string[];Parameters
|
Parameter |
Type |
Description |
|---|---|---|
|
stringIds |
number[] |
A list of string IDs to retrieve |
|
useDefaultString |
boolean |
(Optional) Whether to return the default string if an ID is not found |
Returns:
string[]
A list of localized strings corresponding to the given string IDs