summaryrefslogtreecommitdiffstats
path: root/test/src/test-vxml-mmi-http.cpp
diff options
context:
space:
mode:
authorStefan Radomski <radomski@tk.informatik.tu-darmstadt.de>2014-08-15 10:08:41 (GMT)
committerStefan Radomski <radomski@tk.informatik.tu-darmstadt.de>2014-08-15 10:08:41 (GMT)
commit9149b28c87c7a037dfd244aa5d4c1409b6593dca (patch)
tree939c00d28864910a0ca8a67e70fadae9b6f05cc7 /test/src/test-vxml-mmi-http.cpp
parent322e868668a1e5b9595a21737aabe8d0d8b8d275 (diff)
downloaduscxml-9149b28c87c7a037dfd244aa5d4c1409b6593dca.zip
uscxml-9149b28c87c7a037dfd244aa5d4c1409b6593dca.tar.gz
uscxml-9149b28c87c7a037dfd244aa5d4c1409b6593dca.tar.bz2
More JVoiceXML integration
Diffstat (limited to 'test/src/test-vxml-mmi-http.cpp')
-rw-r--r--test/src/test-vxml-mmi-http.cpp12
1 files changed, 7 insertions, 5 deletions
diff --git a/test/src/test-vxml-mmi-http.cpp b/test/src/test-vxml-mmi-http.cpp
index 0e4f5a9..2b2cd25 100644
--- a/test/src/test-vxml-mmi-http.cpp
+++ b/test/src/test-vxml-mmi-http.cpp
@@ -22,7 +22,7 @@
#include "XGetopt.h"
#endif
-#define ISSUE_REQUEST(name) {\
+#define ISSUE_REQUEST(name, block) {\
Arabica::DOM::Document<std::string> name##XML = name.toXML(true);\
name##XML.getDocumentElement().setPrefix("mmi");\
std::stringstream name##XMLSS;\
@@ -31,7 +31,8 @@
std::cout << "SEND:" << std::endl << name##XMLSS.str() << std::flush;\
name##URL.setOutContent(name##XMLSS.str());\
name##URL.addOutHeader("Content-type", "application/xml");\
- name##URL.download(false);\
+ name##URL.download(block);\
+ std::cout << "OK" << std::endl << std::flush;\
}
using namespace uscxml;
@@ -144,9 +145,10 @@ int main(int argc, char** argv) {
newCtxReq.source = source;
newCtxReq.target = target;
newCtxReq.requestId = uscxml::UUID::getUUID();
-
+
Requests[newCtxReq.requestId] = &newCtxReq;
- ISSUE_REQUEST(newCtxReq);
+
+ ISSUE_REQUEST(newCtxReq, false);
while(Replies.find(newCtxReq.requestId) == Replies.end())
Cond.wait(Mutex);
@@ -160,7 +162,7 @@ int main(int argc, char** argv) {
//"https://raw.githubusercontent.com/Roland-Taizun-Azhar/TaskAssistance-Project/master/WebContent/hello.vxml";
Requests[startReq.requestId] = &startReq;
- ISSUE_REQUEST(startReq);
+ ISSUE_REQUEST(startReq, false);
while(Replies.find(startReq.requestId) == Replies.end())
Cond.wait(Mutex);