| CCXML 1.0-W3C Development Guide | Home | Frameset Home |
<move> tag is used to add an event endpoint to an executing CCXML thread of control. When an endpoint is added to a thread of control, events originating from that endpoint will be delivered to that thread's currently executing CCXML document.source or event attribute must be specified when using the moveelement, but not both, otherwise an error.fetch event is thrown.| event | Data Type: (ECMAScript Expression) | Default: none - attribute is optional |
| The event attribute specifies the event object to be sent to the target session to provide notifaction. The event endpoint may also be sent along with the event, if any. | ||
| sessionid | Data Type: (ECMAScript Expression) | Default: none - attribute is required |
| The sessionid attribute indicates the thread of control to which the endpoint will be added. | ||
| source | Data Type: (ECMAScript Expression) | Default: Optional |
The source attribute specifies an ECMAScript expression which evaluates to a connectionID or dialogID. The event source that is associated with the identifier is then moved to the target specified in the sessionid attribute. If this attribute contains an invalid value, an error.semantic event is thrown. | ||
| <?xml version="1.0" encoding="UTF-8"?>
<ccxml version="1.0" xmlns="http://www.w3.org/2002/09/ccxml"> <meta name="author" content="Jeff Menkel"/> <meta name="copyright" content="2007 Voxeo Corporation"/> <meta name="maintainer" content="YOUR_EMAIL@HERE.COM"/> <var name="conn_id" expr="''"/> <var name="session2" expr="''"/> <var name="success" expr="false"/> <var name="statevar" expr="'init'"/> <eventprocessor statevariable="statevar"> <transition state="init" event="connection.alerting"> <createccxml next="'move_two.xml'" sessionid="session2"/> <log expr="'Answering the call...'"/> <accept connectionid="event$.connectionid" /> <assign name="conn_id" expr="event$.connectionid"/> <assign name="statevar" expr="'alerting'"/> </transition> <transition state="alerting" event="ccxml.created"> <move source="conn_id" sessionid="session2"/> <assign name="statevar" expr="'moving'"/> <log expr="'*** Moving the connection ***'"/> </transition> <transition state="moving" event="move.successful"> <if cond="conn_id==event$.sourceid"> <if cond="'move.successful'==event$.name"> <assign name="success" expr="true"/> </if> </if> </transition> <transition event="ccxml.exit"> <if cond="session.connections[conn_id]==undefined"> <log expr="'Removal complete. Good work soldier.'"/> </if> <if cond="success"> <log expr="'The move completed successfully!'"/> </if> <exit/> </transition> </eventprocessor> </ccxml> |
| ANNOTATIONS: EXISTING POSTS |
| login |