public final class Record extends AbstractXmlNode
<record> element is an input item that collects a
recording from the user.| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
ATTRIBUTE_BEEP
If true, a tone is emitted just prior to recording.
|
static java.lang.String |
ATTRIBUTE_COND
An expression that must evaluate to true after conversion to boolean
in order for the form item to be visited.
|
static java.lang.String |
ATTRIBUTE_DTMFTERM
If true, any DTMF keypress not matched by an active grammar will be
treated as a match of an active (anonymous) local DTMF grammar.
|
static java.lang.String |
ATTRIBUTE_EXPR
The initial value of the form item variable; default is ECMAScript
undefined.
|
static java.lang.String |
ATTRIBUTE_FINALSILENCE
The interval of silence that indicates end of speech.
|
static java.lang.String |
ATTRIBUTE_MAXTIME
The maximum duration to record.
|
static java.lang.String |
ATTRIBUTE_MODAL
If this is true (the default) all non-local speech and DTMF grammars
are not active while making the recording.
|
static java.lang.String |
ATTRIBUTE_NAME
The input item variable that will hold the recording.
|
protected static java.util.ArrayList<java.lang.String> |
ATTRIBUTE_NAMES
Supported attribute names for this node.
|
static java.lang.String |
ATTRIBUTE_TYPE
The media format of the resulting recording.
|
static java.lang.String |
TAG_NAME
Name of the tag.
|
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE| Constructor and Description |
|---|
Record()
Construct a new record object without a node.
|
| Modifier and Type | Method and Description |
|---|---|
Text |
addText(java.lang.String text)
Create a new text within this node.
|
protected boolean |
canContainChild(java.lang.String tagName)
Can the specified sub-tag be contained within this node?
|
java.util.Collection<java.lang.String> |
getAttributeNames()
Returns a collection of permitted attribute names for the node.
|
java.lang.String |
getBeep()
Retrieve the beep attribute.
|
java.lang.String |
getCond()
Retrieve the cond attribute.
|
java.lang.String |
getDtmfterm()
Retrieve the dtmfterm attribute.
|
java.lang.String |
getExpr()
Retrieve the expr attribute.
|
java.lang.String |
getFinalsilence()
Retrieve the finalsilence attribute.
|
java.lang.String |
getMaxtime()
Retrieve the maxtime attribute.
|
long |
getMaxtimeAsMsec()
Retrieves the maxtime attribute as msec.
|
java.lang.String |
getModal()
Retrieve the modal attribute.
|
java.lang.String |
getName()
Retrieve the name attribute.
|
java.lang.String |
getTagName()
Get the name of the tag for the derived node.
|
java.lang.String |
getType()
Retrieve the type attribute.
|
boolean |
isModal()
Checks if this record is modal.
|
XmlNode |
newInstance(org.w3c.dom.Node n,
XmlNodeFactory<? extends XmlNode> factory)
Create a new instance for the given node.
|
void |
setBeep(java.lang.String beep)
Set the beep attribute.
|
void |
setCond(java.lang.String cond)
Set the cond attribute.
|
void |
setDtmfterm(java.lang.String dtmfterm)
Set the dtmfterm attribute.
|
void |
setExpr(java.lang.String expr)
Set the expr attribute.
|
void |
setFinalsilence(java.lang.String finalsilence)
Set the finalsilence attribute.
|
void |
setMaxtime(java.lang.String maxtime)
Set the maxtime attribute.
|
void |
setModal(boolean modal)
Set the modal attribute.
|
void |
setModal(java.lang.String modal)
Set the modal attribute.
|
void |
setName(java.lang.String name)
Set the name attribute.
|
void |
setType(java.lang.String type)
Set the type attribute.
|
addChild, addChild, appendChild, appendChild, appendDeepClone, cloneNode, compareDocumentPosition, equals, getAttribute, getAttributes, getBaseURI, getChildNodes, getChildNodes, getChildren, getDefinedAttributeNames, getFeature, getFirstChild, getFirstLevelTextContent, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNode, getNodeFactory, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getOwnerXmlDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttribute, hasAttributes, hasChildNodes, hashCode, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setAttribute, setNodeValue, setPrefix, setTextContent, setUserData, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitaddChild, getAttribute, getChildNodes, getChildren, getNode, setAttributeappendChild, cloneNode, compareDocumentPosition, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setTextContent, setUserDatapublic static final java.lang.String TAG_NAME
public static final java.lang.String ATTRIBUTE_NAME
public static final java.lang.String ATTRIBUTE_EXPR
public static final java.lang.String ATTRIBUTE_COND
public static final java.lang.String ATTRIBUTE_MODAL
public static final java.lang.String ATTRIBUTE_BEEP
public static final java.lang.String ATTRIBUTE_MAXTIME
public static final java.lang.String ATTRIBUTE_FINALSILENCE
public static final java.lang.String ATTRIBUTE_DTMFTERM
public static final java.lang.String ATTRIBUTE_TYPE
protected static final java.util.ArrayList<java.lang.String> ATTRIBUTE_NAMES
public Record()
This is necessary for the node factory.
VoiceXmlNodeFactorypublic java.lang.String getTagName()
public XmlNode newInstance(org.w3c.dom.Node n, XmlNodeFactory<? extends XmlNode> factory)
Each XmlNode can serve as a prototype in a
XmlNodeFactory to produce a collection of
child nodes. Factories can then use the prototype pattern to
produce new nodes.
n - The node to encapsulate.factory - the factroy that calls this method.XmlNodeFactorypublic java.lang.String getName()
ATTRIBUTE_NAMEpublic void setName(java.lang.String name)
name - Value of the name attribute.ATTRIBUTE_NAMEpublic java.lang.String getExpr()
ATTRIBUTE_EXPRpublic void setExpr(java.lang.String expr)
expr - Value of the expr attribute.ATTRIBUTE_EXPRpublic java.lang.String getCond()
ATTRIBUTE_CONDpublic void setCond(java.lang.String cond)
cond - Value of the cond attribute.ATTRIBUTE_CONDpublic java.lang.String getModal()
ATTRIBUTE_MODALpublic boolean isModal()
true if the record is modal.public void setModal(java.lang.String modal)
modal - Value of the modal attribute.ATTRIBUTE_MODALpublic void setModal(boolean modal)
modal - Value of the modal attribute.ATTRIBUTE_MODALpublic java.lang.String getBeep()
ATTRIBUTE_BEEPpublic void setBeep(java.lang.String beep)
beep - Value of the beep attribute.ATTRIBUTE_BEEPpublic java.lang.String getMaxtime()
ATTRIBUTE_MAXTIMEpublic long getMaxtimeAsMsec()
-1 if the value can not
be converted to a number.public void setMaxtime(java.lang.String maxtime)
maxtime - Value of the maxtime attribute.ATTRIBUTE_MAXTIMEpublic java.lang.String getFinalsilence()
ATTRIBUTE_FINALSILENCEpublic void setFinalsilence(java.lang.String finalsilence)
finalsilence - Value of the finalsilence attribute.ATTRIBUTE_FINALSILENCEpublic java.lang.String getDtmfterm()
ATTRIBUTE_DTMFTERMpublic void setDtmfterm(java.lang.String dtmfterm)
dtmfterm - Value of the dtmfterm attribute.ATTRIBUTE_DTMFTERMpublic java.lang.String getType()
ATTRIBUTE_TYPEpublic void setType(java.lang.String type)
type - Value of the type attribute.ATTRIBUTE_TYPEpublic Text addText(java.lang.String text)
text - The text to be added.protected boolean canContainChild(java.lang.String tagName)
canContainChild in class AbstractXmlNodetagName - Name of child.public java.util.Collection<java.lang.String> getAttributeNames()
getAttributeNames in interface XmlNodegetAttributeNames in class AbstractXmlNode