public interface SsmlParsingStrategy
extends java.lang.Cloneable
<prompt> tag into an SSML document that can be sent to the
speech synthesizer.
The main purpose is to evaluate all expressions. Since the task is very
similar to evaluating a tag with a TagStrategy it is advisable to use
a single source for evaluation of the tags.
Execution of an SsmlParsingStrategy comprises the following
steps:
clone()getAttributes(VoiceXmlInterpreterContext, FormInterpretationAlgorithm, VoiceXmlNode)
evalAttributes(VoiceXmlInterpreterContext)
validateAttributes(DataModel)cloneNode(SsmlParser, DataModel, SsmlDocument, SsmlNode, VoiceXmlNode)
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
clone()
Creates a new instance of this strategy.
|
org.jvoicexml.xml.SsmlNode |
cloneNode(SsmlParser parser,
DataModel model,
org.jvoicexml.xml.ssml.SsmlDocument document,
org.jvoicexml.xml.SsmlNode parent,
org.jvoicexml.xml.VoiceXmlNode node)
Creates a clone of this node in the given document.
|
void |
evalAttributes(VoiceXmlInterpreterContext context)
Evaluates all attributes which have to be evaluated by the scripting
environment.
|
void |
getAttributes(VoiceXmlInterpreterContext context,
FormInterpretationAlgorithm fia,
org.jvoicexml.xml.VoiceXmlNode node)
Retrieves all attributes specified by the given node or by a
<property> tag and stores their values in the working
copy of this strategy. |
java.util.Collection<java.lang.String> |
getEvalAttributes()
Retrieves the names of all attributes, which have to be evaluated by the
scripting environment.
|
void |
validateAttributes(DataModel model)
Validates the attributes of the current node.
|
java.lang.Object clone()
java.util.Collection<java.lang.String> getEvalAttributes()
null if the
related node has not attributes to be evaluated.void getAttributes(VoiceXmlInterpreterContext context, FormInterpretationAlgorithm fia, org.jvoicexml.xml.VoiceXmlNode node)
<property> tag and stores their values in the working
copy of this strategy.context - The current VoiceXML interpreter context.fia - The current form interpretation algorithm, maybe
null if there is no current fia.node - The node to process.void evalAttributes(VoiceXmlInterpreterContext context) throws SemanticError
context - The current VoiceXML interpreter context.SemanticError - Error evaluating a variable.void validateAttributes(DataModel model) throws ErrorEvent
model - the employed data modelErrorEvent - Validation failed.org.jvoicexml.xml.SsmlNode cloneNode(SsmlParser parser, DataModel model, org.jvoicexml.xml.ssml.SsmlDocument document, org.jvoicexml.xml.SsmlNode parent, org.jvoicexml.xml.VoiceXmlNode node) throws SemanticError
parser - the SSML parser.model - the employed data model scripting expressions.document - the SSML target document.parent - parent node of the node to clone.node - the node to clone.null may be returned to
indicate that the child nodes of node need no
further processing.SemanticError - Error evaluating the node.