| Can I use different audio paths for each language my application supports? |
| Categories: Audium OpenSDK, Audium Studio (3.4.x) |
| Article ID: | 78 |
| Last updated: | January 08, 2007 |
| User Opinions |
|
No users have voted.
|
|
Thank you for rating this answer.
|
SUMMARY
This article explains how to access audio files that are stored in separate folders by language.
SYMPTOMS
Developer is creating an Audium application that will support multiple languages, and wants to separate the audio files for each language into their own folder.
RESOLUTION
There are several different ways to accomplish this:
1) The default audio path can be modified during application execution by custom code (i.e dynamic configurations, standard action elements, etc.) by using the setDefaultAudioPath(String path) method of the APIBase class. Audium Call Services always passes an object that is derived from APIBase to your custom code. You can store your various language audio files in different folders, and then dynamically change the default audio path once the user has selected their desired language. Note that this solution assumes that all languages will use the same filenames.
2) If you prefer to avoid Java code, you can implement similar functionality using substitution. Since substitution can be used in the URI setting of audio items, a pseudo default audio path can be created. For example, first set the audio path you wish to use in session or element data. Then, before each element that should use an audio path other than the true default audio path, uncheck the "Use Default Audio Path" setting, and then insert a substitution before the audio filename. This substitution should pull the path from the previously created session or element data. At program execution, this substitution will be replaced by the correct audio path for the chosen language, and the filename will be appended to the end. This solution also assumes that all languages will use the same filenames.
3) Create a separate Audium application for each language you need to support, and then perform an application transfer to it after the caller selects their preferred language. While this solution involves the most overhead (e.g. maintaining several copies of the same application), it does allow more flexibility. For example, you can specify different TTS backups for each language, and the audio files for each language do not need to have the same name.
|
| Visitor Comments |
|
No visitor comments posted. Post a comment
|
| Attachments |
|
No attachments were found.
|