}
-std::string Launcher::getSignalUSR2InputFile() const throw() {
+std::string Launcher::getSignalUSR2InputFile() const {
return (getInitialWorkingDirectory() + "/" + SIGUSR2_TASKS_INPUT_FILENAME);
}
-std::string Launcher::getSignalUSR2OutputFile() const throw() {
+std::string Launcher::getSignalUSR2OutputFile() const {
return (getInitialWorkingDirectory() + "/" + SIGUSR2_TASKS_OUTPUT_FILENAME);
}
-void Launcher::servicesFromXML(const anna::xml::Node* servicesNode, bool bindResources) throw(anna::RuntimeException) {
+void Launcher::servicesFromXML(const anna::xml::Node* servicesNode, bool bindResources) noexcept(false) {
CommandLine& cl(anna::CommandLine::instantiate());
bool allLogsDisabled = cl.exists("disableLogs");
}
-void Launcher::loadServicesFromFile(const std::string & xmlPathFile, bool bindResources) throw(anna::RuntimeException) {
+void Launcher::loadServicesFromFile(const std::string & xmlPathFile, bool bindResources) noexcept(false) {
if (xmlPathFile == "null" || xmlPathFile == "") {
LOGWARNING(anna::Logger::warning("Ignoring services configuration on start: empty or 'null' string provided as xml file. Use management interface (operation 'services') in order to add services", ANNA_FILE_LOCATION));
}
-void Launcher::loadServicesFromXMLString(const std::string & xmlString, bool bindResources) throw(anna::RuntimeException) {
+void Launcher::loadServicesFromXMLString(const std::string & xmlString, bool bindResources) noexcept(false) {
anna::xml::DocumentMemory xmlDocument; // has private copy constructor defined but not implemented to avoid inhenrit/copy (is very heavy)
anna::xml::DTDMemory xmlDTD;
}
-anna::Millisecond Launcher::checkTimeMeasure(const std::string ¶meter, const std::string &value) throw(anna::RuntimeException) {
+anna::Millisecond Launcher::checkTimeMeasure(const std::string ¶meter, const std::string &value) noexcept(false) {
if(anna::functions::isLike("^[0-9]+$", value)) { // para incluir numeros decimales: ^[0-9]+(.[0-9]+)?$
int msecs;
throw RuntimeException(msg, ANNA_FILE_LOCATION);
}
-bool Launcher::setWorkingNode(const std::string &name) throw() {
+bool Launcher::setWorkingNode(const std::string &name) {
bool result = false;
anna::diameter::comm::OriginHostManager &ohm = anna::diameter::comm::OriginHostManager::instantiate();
return result;
}
-anna::diameter::comm::OriginHost *Launcher::getOriginHost(const std::string &name) const throw(anna::RuntimeException) {
+anna::diameter::comm::OriginHost *Launcher::getOriginHost(const std::string &name) const noexcept(false) {
anna::diameter::comm::OriginHostManager &ohm = anna::diameter::comm::OriginHostManager::instantiate();
anna::diameter::comm::OriginHost *result = ohm.getOriginHost(name);
return result;
}
-anna::diameter::comm::OriginHost *Launcher::getOriginHost(const anna::diameter::codec::Message &message) const throw(anna::RuntimeException) {
+anna::diameter::comm::OriginHost *Launcher::getOriginHost(const anna::diameter::codec::Message &message) const noexcept(false) {
std::string originHost = message.getAvp(anna::diameter::helpers::base::AVPID__Origin_Host)->getDiameterIdentity()->getValue();
return (getOriginHost(originHost));
}
-anna::diameter::comm::OriginHost *Launcher::getOriginHost(const anna::DataBlock &messageDataBlock) const throw(anna::RuntimeException) {
+anna::diameter::comm::OriginHost *Launcher::getOriginHost(const anna::DataBlock &messageDataBlock) const noexcept(false) {
std::string originHost = anna::diameter::helpers::base::functions::getOriginHost(messageDataBlock);
return (getOriginHost(originHost));
}
-bool Launcher::uniqueOriginHost() const throw() {
+bool Launcher::uniqueOriginHost() const {
anna::diameter::comm::OriginHostManager &ohm = anna::diameter::comm::OriginHostManager::instantiate();
return (ohm.size() == 1);
}
-void Launcher::updateOperatedOriginHostWithMessage(const anna::diameter::codec::Message &message) throw(anna::RuntimeException) {
+void Launcher::updateOperatedOriginHostWithMessage(const anna::diameter::codec::Message &message) noexcept(false) {
if (!a_operatedHost) // priority for working node by mean 'node' operation
a_operatedHost = getOriginHost(message);
}
-void Launcher::updateOperatedOriginHostWithMessage(const anna::DataBlock &messageDataBlock) throw(anna::RuntimeException) {
+void Launcher::updateOperatedOriginHostWithMessage(const anna::DataBlock &messageDataBlock) noexcept(false) {
if (!a_operatedHost) // priority for working node by mean 'node' operation
a_operatedHost = getOriginHost(messageDataBlock);
}
-anna::diameter::comm::OriginHost *Launcher::getWorkingNode() const throw(anna::RuntimeException) {
+anna::diameter::comm::OriginHost *Launcher::getWorkingNode() const noexcept(false) {
if(!a_workingNode)
throw anna::RuntimeException("Working node not identified (try to load services)", ANNA_FILE_LOCATION);
return a_workingNode;
}
-anna::diameter::comm::OriginHost *Launcher::getOperatedHost() const throw(anna::RuntimeException) {
+anna::diameter::comm::OriginHost *Launcher::getOperatedHost() const noexcept(false) {
if(!a_operatedHost)
throw anna::RuntimeException("Node not identified (try to force a specific Origin-Host with 'node' operation)", ANNA_FILE_LOCATION);
a_operatedHost = op;
}
-MyDiameterEntity *Launcher::getOperatedEntity() const throw(anna::RuntimeException) {
+MyDiameterEntity *Launcher::getOperatedEntity() const noexcept(false) {
MyDiameterEntity *result = (MyDiameterEntity *)(getOperatedHost()->getEntity());
if (!result)
throw anna::RuntimeException("No entity configured for the operated node", ANNA_FILE_LOCATION);
return result;
}
-MyLocalServer *Launcher::getOperatedServer() const throw(anna::RuntimeException) {
+MyLocalServer *Launcher::getOperatedServer() const noexcept(false) {
MyLocalServer *result = (MyLocalServer *)(getOperatedHost()->getDiameterServer());
if (!result)
throw anna::RuntimeException("No local server configured for the operated node", ANNA_FILE_LOCATION);
return result;
}
-MyDiameterEngine *Launcher::getOperatedEngine() const throw(anna::RuntimeException) {
+MyDiameterEngine *Launcher::getOperatedEngine() const noexcept(false) {
return (MyDiameterEngine *)getOperatedHost()->getCommEngine(); // never will be NULL
}
void Launcher::initialize()
-throw(anna::RuntimeException) {
+noexcept(false) {
anna::comm::Application::initialize();
CommandLine& cl(anna::CommandLine::instantiate());
anna::comm::Communicator::WorkMode::_v workMode(anna::comm::Communicator::WorkMode::Single);
}
void Launcher::run()
-throw(anna::RuntimeException) {
+noexcept(false) {
LOGMETHOD(anna::TraceMethod tm("Launcher", "run", ANNA_FILE_LOCATION));
CommandLine& cl(anna::CommandLine::instantiate());
anna::diameter::stack::Engine::instantiate();
a_communicator->accept();
}
-bool Launcher::getDataBlockFromHexFile(const std::string &pathfile, anna::DataBlock &db) const throw(anna::RuntimeException) {
+bool Launcher::getDataBlockFromHexFile(const std::string &pathfile, anna::DataBlock &db) const noexcept(false) {
// Get hex string
static char buffer[8192];
std::ifstream infile(pathfile.c_str(), std::ifstream::in);
return false;
}
-void Launcher::resetStatistics() throw() {
+void Launcher::resetStatistics() {
if (a_workingNode) {
a_workingNode->getCommEngine()->resetStatistics();
}
}
}
-void Launcher::resetCounters() throw() {
+void Launcher::resetCounters() {
anna::diameter::comm::OamModule::instantiate().resetCounters();
anna::diameter::comm::ApplicationMessageOamModule::instantiate().resetCounters();
anna::diameter::codec::OamModule::instantiate().resetCounters();
}
-void Launcher::signalTerminate() throw(anna::RuntimeException) {
+void Launcher::signalTerminate() noexcept(false) {
LOGMETHOD(anna::TraceMethod tm("Launcher", "signalTerminate", ANNA_FILE_LOCATION));
forceCountersRecord();
comm::Application::signalTerminate ();
}
-void Launcher::signalUSR2() throw(anna::RuntimeException) {
+void Launcher::signalUSR2() noexcept(false) {
std::string inputFile = getSignalUSR2InputFile();
std::string outputFile = getSignalUSR2OutputFile();
}
-void Launcher::logStatisticsSamples(const std::string &conceptsList) throw() {
+void Launcher::logStatisticsSamples(const std::string &conceptsList) {
anna::statistics::Engine &statEngine = anna::statistics::Engine::instantiate();
if(conceptsList == "all") {
}
-bool Launcher::eventOperation(const std::string &operation, std::string &response) throw(anna::RuntimeException) {
+bool Launcher::eventOperation(const std::string &operation, std::string &response) noexcept(false) {
bool result = true;
}
anna::xml::Node* Launcher::asXML(anna::xml::Node* parent) const
-throw() {
+{
anna::xml::Node* result = parent->createChild("launcher");
anna::comm::Application::asXML(result);
// Timming:
}
anna::xml::Node* Launcher::oamAsXML(anna::xml::Node* parent) const
-throw() {
+{
anna::xml::Node* result = parent->createChild("Oam");
// OAM:
}
anna::xml::Node* Launcher::statsAsXML(anna::xml::Node* parent) const
-throw() {
+{
anna::xml::Node* result = parent->createChild("Statistics");
// Statistics: