Hi
I have to change the application modifier element based on the language user has selected. For example there are several texts for TTS for different language. Based on the language selected by the user ,I want to change the xml:lang parameter. Now I am using multiple Application Modifier element but want to know how can I do that using an Action element ?. How to get the current lang set in the application and change it dynamically ?( I mean programmatically).
help / hint on this much appreciated.
Thanks in Advance.
Raghu
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Hi Raghu,
You can set it via action element specifying a java class like so:
public class SetDocumentLanguage extends ActionElementBase { @Override public void doAction(String name, ActionElementData data) throws AudiumException { String currentDocLang = data.getDocumentLanguage(); data.setDocumentLanguage("en-US"); } }
You can also set your document language in an OnCallStart class so it applies to the entire application flow transparently.
-Ryan
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Comments
0 comments
Please sign in to leave a comment.