diff options
Diffstat (limited to 'src/uscxml/Factory.cpp')
-rw-r--r-- | src/uscxml/Factory.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/uscxml/Factory.cpp b/src/uscxml/Factory.cpp index a66b024..5f3d172 100644 --- a/src/uscxml/Factory.cpp +++ b/src/uscxml/Factory.cpp @@ -607,6 +607,23 @@ void EventHandlerImpl::returnEvent(Event& event) { _interpreter->receive(event); } +void DataModelImpl::throwErrorExecution(const std::string& cause) { + uscxml::Event exc; + exc.data.compound["exception"] = uscxml::Data(cause, uscxml::Data::VERBATIM); + exc.name = "error.execution"; + exc.eventType = uscxml::Event::PLATFORM; + throw exc; +} + +void DataModelImpl::throwErrorPlatform(const std::string& cause) { + uscxml::Event exc; + exc.data.compound["exception"] = uscxml::Data(cause, uscxml::Data::VERBATIM); + exc.name = "error.platform"; + exc.eventType = uscxml::Event::PLATFORM; + throw exc; +} + + Factory* Factory::_instance = NULL; std::string Factory::pluginPath; }
\ No newline at end of file |