X-Git-Url: https://git.teslayout.com/public/public/public/?p=anna.git;a=blobdiff_plain;f=source%2Fcomm%2FHost.cpp;fp=source%2Fcomm%2FHost.cpp;h=818483b22704dda492b40a880f661e371e94fb85;hp=43ff56190d8894c3cdc7a99f80439af7a57fd2c5;hb=5a6cba5fde2b2f538a7515f8293cc0a8d9589dfa;hpb=af9c86ffb0e28d35ad94d99c5f77e41578c972b4 diff --git a/source/comm/Host.cpp b/source/comm/Host.cpp index 43ff561..818483b 100644 --- a/source/comm/Host.cpp +++ b/source/comm/Host.cpp @@ -29,24 +29,24 @@ comm::Host::~Host() { } int comm::Host::SortBy::value(const Server* server) -throw() { +{ return server->getRemotePort(); } const comm::Server* comm::Host::find_server(const int remotePort) const -throw() { +{ return a_servers.find(remotePort); } comm::Server* comm::Host::find_server(const int remotePort) -throw() { +{ return a_servers.find(remotePort); } comm::Server* comm::Host::createServer(const string& name, const int remotePort, const bool autoRecovery, comm::TransportFactory* transportFactory, const bool ignoreIncomingMessages, const bool doConnect) -throw(RuntimeException) { +noexcept(false) { return add(createServer(ServerAllocator(name, *this, remotePort, autoRecovery, transportFactory, ignoreIncomingMessages)), remotePort, doConnect); } @@ -58,21 +58,21 @@ throw(RuntimeException) { // ServerSocket remoto. //------------------------------------------------------------------------------- comm::Server* comm::Host::createServer(const ServerAllocator& serverAllocator) -throw(RuntimeException) { +noexcept(false) { Server* result = serverAllocator.apply(); result->setIgnoreIncomingMessages(serverAllocator.getIgnoreIncomingMessages()); return result; } void comm::Host::assign(const Device* device) -throw(RuntimeException) { +noexcept(false) { if(contains(device) == false) a_devices.push_back(device); } string comm::Host::asString() const -throw() { +{ string result; result = "comm::Host { Name: "; result += getName(); @@ -92,7 +92,7 @@ throw() { xml::Node* comm::Host::asXML(xml::Node* parent) const -throw(RuntimeException) { +noexcept(false) { xml::Node* host = parent->createChild("comm.Host"); xml::Node* node; host->createAttribute("Name", getName()); @@ -111,7 +111,7 @@ throw(RuntimeException) { comm::Server* comm::Host::add(comm::Server* result, const int remotePort, const bool doConnect) -throw() { +{ result->a_sequence = a_servers.size(); a_servers.add(result);