summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorStefan Radomski <radomski@tk.informatik.tu-darmstadt.de>2014-08-21 11:19:08 (GMT)
committerStefan Radomski <radomski@tk.informatik.tu-darmstadt.de>2014-08-21 11:19:08 (GMT)
commita3fb1daf5b4e58471cc714853636025b6cac9aed (patch)
tree03f60a2f396f7d339a0733099da0f56f64c8d822 /src
parent7454d99f1d02c68706da1ed6237a5f391291942d (diff)
downloaduscxml-a3fb1daf5b4e58471cc714853636025b6cac9aed.zip
uscxml-a3fb1daf5b4e58471cc714853636025b6cac9aed.tar.gz
uscxml-a3fb1daf5b4e58471cc714853636025b6cac9aed.tar.bz2
Reactiveted new CMake policies and some more documentation
Diffstat (limited to 'src')
-rw-r--r--src/bindings/swig/csharp/CMakeLists.txt2
-rw-r--r--src/bindings/swig/uscxml_beautify.i22
-rw-r--r--src/bindings/swig/uscxml_ignores.i6
-rw-r--r--src/uscxml/Factory.cpp4
4 files changed, 33 insertions, 1 deletions
diff --git a/src/bindings/swig/csharp/CMakeLists.txt b/src/bindings/swig/csharp/CMakeLists.txt
index ee37bf7..384507b 100644
--- a/src/bindings/swig/csharp/CMakeLists.txt
+++ b/src/bindings/swig/csharp/CMakeLists.txt
@@ -78,7 +78,7 @@ if (DMCS_EXECUTABLE OR CSC_EXECUTABLE)
COMMENT "Creating umundoCSharp.dll for Mono ...")
endif()
- add_dependencies(csharp umundoNativeCSharp)
+ add_dependencies(csharp uscxmlNativeCSharp)
if (BUILD_TESTS)
add_dependencies(ALL_TESTS csharp)
endif()
diff --git a/src/bindings/swig/uscxml_beautify.i b/src/bindings/swig/uscxml_beautify.i
index bf54958..751be78 100644
--- a/src/bindings/swig/uscxml_beautify.i
+++ b/src/bindings/swig/uscxml_beautify.i
@@ -114,6 +114,10 @@
};
+%{
+ #include <glog/logging.h>
+%}
+
%extend uscxml::Data {
std::vector<std::string> getCompoundKeys() {
std::vector<std::string> keys;
@@ -124,4 +128,22 @@
}
return keys;
}
+
+ std::string getXML() {
+ if (!self->node)
+ return "";
+
+ std::stringstream ss;
+ ss << self->node;
+ return ss.str();
+ }
+
+ void setXML(const std::string& xml) {
+ NameSpacingParser parser = NameSpacingParser::fromXML(xml);
+ if (!parser.errorsReported()) {
+ self->node = parser.getDocument();
+ } else {
+ LOG(ERROR) << "Cannot parse message as XML: " << parser.errors();
+ }
+ }
};
diff --git a/src/bindings/swig/uscxml_ignores.i b/src/bindings/swig/uscxml_ignores.i
index f7d3dad..c8fc372 100644
--- a/src/bindings/swig/uscxml_ignores.i
+++ b/src/bindings/swig/uscxml_ignores.i
@@ -189,6 +189,12 @@
%ignore uscxml::SendRequest::fromXML;
%ignore uscxml::InvokeRequest::fromXML;
+// HTTPServer
+
+%ignore uscxml::HTTPServer::wsSend;
+%ignore uscxml::HTTPServer::wsBroadcast;
+%ignore uscxml::HTTPServer::reply;
+
// Data
diff --git a/src/uscxml/Factory.cpp b/src/uscxml/Factory.cpp
index ce09a27..9ebc0d8 100644
--- a/src/uscxml/Factory.cpp
+++ b/src/uscxml/Factory.cpp
@@ -445,14 +445,17 @@ void Factory::listComponents() {
{
std::cout << "Available Datamodels:" << std::endl;
LIST_COMPONENTS(DataModelImpl, _dataModels);
+ std::cout << std::endl;
}
{
std::cout << "Available Invokers:" << std::endl;
LIST_COMPONENTS(InvokerImpl, _invokers);
+ std::cout << std::endl;
}
{
std::cout << "Available I/O Processors:" << std::endl;
LIST_COMPONENTS(IOProcessorImpl, _ioProcessors);
+ std::cout << std::endl;
}
{
std::cout << "Available Elements:" << std::endl;
@@ -461,6 +464,7 @@ void Factory::listComponents() {
std::cout << "\t" << iter->second->getNamespace() << " / " << iter->second->getLocalName() << std::endl;
iter++;
}
+ std::cout << std::endl;
}
}