diff options
author | Stefan Radomski <radomski@tk.informatik.tu-darmstadt.de> | 2013-07-22 12:38:43 (GMT) |
---|---|---|
committer | Stefan Radomski <radomski@tk.informatik.tu-darmstadt.de> | 2013-07-22 12:38:43 (GMT) |
commit | f2d8c967076e5d8ebd3ca718e14edef8acb5f87c (patch) | |
tree | 0bed80b7ff8081a6108e7c847a4489de272679c8 /src/uscxml/Interpreter.cpp | |
parent | 7bd0256239f247ed01ee6c673e31283c794bb3d0 (diff) | |
download | uscxml-f2d8c967076e5d8ebd3ca718e14edef8acb5f87c.zip uscxml-f2d8c967076e5d8ebd3ca718e14edef8acb5f87c.tar.gz uscxml-f2d8c967076e5d8ebd3ca718e14edef8acb5f87c.tar.bz2 |
Removed iOS project again
Diffstat (limited to 'src/uscxml/Interpreter.cpp')
-rw-r--r-- | src/uscxml/Interpreter.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/uscxml/Interpreter.cpp b/src/uscxml/Interpreter.cpp index 158ea96..8c1b4a6 100644 --- a/src/uscxml/Interpreter.cpp +++ b/src/uscxml/Interpreter.cpp @@ -436,7 +436,7 @@ void InterpreterImpl::processContentElement(const Arabica::DOM::Node<std::string std::string& expr) { if (HAS_ATTR(content, "expr")) { expr = ATTR(content, "expr"); - } else if (content.hasChildNodes()) { + } else if (content.hasChildNodes() || HAS_ATTR(content, "src") || HAS_ATTR(content, "srcexpr")) { processDOMorText(content, dom, text); } else { LOG(ERROR) << "content element does not specify any content."; @@ -455,7 +455,7 @@ void InterpreterImpl::processDOMorText(const Arabica::DOM::Node<std::string>& no LOG(ERROR) << LOCALNAME(node) << " element has relative src or srcexpr URI with no baseURI set."; return; } - if (_cachedURLs.find(sourceURL.asString()) != _cachedURLs.end()) { + if (_cachedURLs.find(sourceURL.asString()) != _cachedURLs.end() && false) { srcContent << _cachedURLs[sourceURL.asString()]; } else { srcContent << sourceURL; @@ -473,8 +473,12 @@ void InterpreterImpl::processDOMorText(const Arabica::DOM::Node<std::string>& no std::auto_ptr<std::istream> ssPtr(ss); Arabica::SAX::InputSource<std::string> inputSource; inputSource.setByteStream(ssPtr); + +// parser.setFeature(Arabica::SAX::FeatureNames<std::string>().external_general, true); + if (parser.parse(inputSource) && parser.getDocument()) { dom = parser.getDocument(); + std::cout << dom; Node<std::string> content = dom.getDocumentElement(); assert(content.getNodeType() == Node_base::ELEMENT_NODE); Node<std::string> container = dom.createElement("container"); @@ -1106,7 +1110,7 @@ void InterpreterImpl::executeContent(const Arabica::DOM::Node<std::string>& cont } std::stringstream srcContent; - if (_cachedURLs.find(scriptUrl.asString()) != _cachedURLs.end()) { + if (_cachedURLs.find(scriptUrl.asString()) != _cachedURLs.end() && false) { srcContent << _cachedURLs[scriptUrl.asString()]; } else { srcContent << scriptUrl; @@ -1313,7 +1317,7 @@ Arabica::XPath::NodeSet<std::string> InterpreterImpl::getStates(const std::vecto Arabica::DOM::Node<std::string> InterpreterImpl::getState(const std::string& stateId) { - if (_cachedStates.find(stateId) != _cachedStates.end()) { + if (_cachedStates.find(stateId) != _cachedStates.end() && false) { return _cachedStates[stateId]; } |