projects
/
anna.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add more utilities for ADML-HTTP image
[anna.git]
/
source
/
app
/
Component.cpp
diff --git
a/source/app/Component.cpp
b/source/app/Component.cpp
index
a77c084
..
c8d0fbc
100644
(file)
--- a/
source/app/Component.cpp
+++ b/
source/app/Component.cpp
@@
-20,7
+20,7
@@
using namespace std;
using namespace anna;
app::Component::Component(const char* className) :
using namespace anna;
app::Component::Component(const char* className) :
- a
_className
(className),
+ a
nna::Component
(className),
a_state(State::Stopped) {
Application& app(app::functions::getApp());
a_state(State::Stopped) {
Application& app(app::functions::getApp());
@@
-32,7
+32,7
@@
app::Component::Component(const char* className) :
}
} else if(Logger::isActive(Logger::Warning) == true) {
string msg(asString());
}
} else if(Logger::isActive(Logger::Warning) == true) {
string msg(asString());
- msg += " |
Not connected to applicatino yet
";
+ msg += " |
Application already running. You may initialize this component manually (lazy initialization)
";
Logger::warning(msg, ANNA_FILE_LOCATION);
}
}
Logger::warning(msg, ANNA_FILE_LOCATION);
}
}
@@
-46,7
+46,7
@@
app::Component::~Component() {
}
void app::Component::addPredecessor(const char* componentName)
}
void app::Component::addPredecessor(const char* componentName)
-
throw()
{
+{
const std::string name(componentName);
if((find(begin(), end(), name)) != end())
const std::string name(componentName);
if((find(begin(), end(), name)) != end())
@@
-63,7
+63,7
@@
throw() {
}
void app::Component::initialize()
}
void app::Component::initialize()
-
throw(RuntimeException
) {
+
noexcept(false
) {
if(a_state == State::Running)
return;
if(a_state == State::Running)
return;
@@
-105,24
+105,17
@@
throw(RuntimeException) {
}
void app::Component::attach()
}
void app::Component::attach()
-
throw(RuntimeException
) {
+
noexcept(false
) {
app::functions::getApp().attach(this);
}
std::string app::Component::asString() const
app::functions::getApp().attach(this);
}
std::string app::Component::asString() const
-throw() {
- std::string result("app::Component { Name: ");
- result += a_className;
- result += " | Reference: ";
- result += functions::asHexString(anna_ptrnumber_cast(this));
- return result += " }";
+{
+ return anna::Component::asString();
}
xml::Node* app::Component::asXML(xml::Node* parent) const
}
xml::Node* app::Component::asXML(xml::Node* parent) const
-throw() {
- xml::Node* result = parent->createChild("app.Component");
- result->createAttribute("Name", a_className);
- result->createAttribute("Reference", functions::asHexString(anna_ptrnumber_cast(this)));
- return result;
+{
+ return anna::Component::asXML(parent);
}
}