X-Git-Url: https://git.teslayout.com/public/public/public/?p=anna.git;a=blobdiff_plain;f=include%2Fanna%2Fdiameter.comm%2FOriginHost.hpp;fp=include%2Fanna%2Fdiameter.comm%2FOriginHost.hpp;h=55f729dfc89368847eecf581a478e6793b76367b;hp=1cc7bc91c54fe68f00e73eaddaa6d101ef2328b5;hb=5a6cba5fde2b2f538a7515f8293cc0a8d9589dfa;hpb=af9c86ffb0e28d35ad94d99c5f77e41578c972b4 diff --git a/include/anna/diameter.comm/OriginHost.hpp b/include/anna/diameter.comm/OriginHost.hpp index 1cc7bc9..55f729d 100644 --- a/include/anna/diameter.comm/OriginHost.hpp +++ b/include/anna/diameter.comm/OriginHost.hpp @@ -70,26 +70,26 @@ public: ~OriginHost() {;} // OriginHost name: - const std::string &getName() const throw(); + const std::string &getName() const ; // Core resources: - anna::diameter::comm::Engine* getCommEngine() const throw() { return a_commEngine; } - unsigned int getApplicationId() const throw() { return a_applicationId; } - anna::diameter::codec::Engine *getCodecEngine() const throw() { return a_codecEngine; } + anna::diameter::comm::Engine* getCommEngine() const { return a_commEngine; } + unsigned int getApplicationId() const { return a_applicationId; } + anna::diameter::codec::Engine *getCodecEngine() const { return a_codecEngine; } - void createEntity(const std::string &entityRepresentation, const anna::Millisecond &bindTimeout, const anna::Millisecond &applicationTimeout) throw(anna::RuntimeException); - anna::diameter::comm::Entity *getEntity() const throw() { return a_entity; } + void createEntity(const std::string &entityRepresentation, const anna::Millisecond &bindTimeout, const anna::Millisecond &applicationTimeout) noexcept(false); + anna::diameter::comm::Entity *getEntity() const { return a_entity; } - void createDiameterServer(const std::string &serverRepresentation, int sessions, const anna::Millisecond &inactivityTimeout, const anna::Millisecond &applicationTimeout, const std::string &ceaPathfile) throw(anna::RuntimeException); - anna::diameter::comm::LocalServer* getDiameterServer() throw() { return a_diameterServer; } - void setRequestRetransmissions(int r) throw() { if (r >= 0) a_requestRetransmissions = r; } + void createDiameterServer(const std::string &serverRepresentation, int sessions, const anna::Millisecond &inactivityTimeout, const anna::Millisecond &applicationTimeout, const std::string &ceaPathfile) noexcept(false); + anna::diameter::comm::LocalServer* getDiameterServer() { return a_diameterServer; } + void setRequestRetransmissions(int r) { if (r >= 0) a_requestRetransmissions = r; } // Messages factory: - anna::diameter::comm::Message *createCommMessage() throw(anna::RuntimeException); - void releaseCommMessage(anna::diameter::comm::Message*) throw(); + anna::diameter::comm::Message *createCommMessage() noexcept(false); + void releaseCommMessage(anna::diameter::comm::Message*) ; // Traffic logs & burst: - void setLogs(const std::string &log, bool splitLog, bool detailedLog, bool dumpLog, const std::string &burstLog) throw() { + void setLogs(const std::string &log, bool splitLog, bool detailedLog, bool dumpLog, const std::string &burstLog) { a_logFile = log; a_splitLog = splitLog; a_detailedLog = detailedLog; @@ -97,26 +97,26 @@ public: a_burstLogFile = burstLog; } - bool logEnabled() const throw() { return (((a_logFile == "") || (a_logFile == "null")) ? false : true); } - void writeLogFile(const anna::DataBlock & db, const std::string &logExtension, const std::string &detail) const throw(); - void writeLogFile(const anna::diameter::codec::Message & decodedMessage, const std::string &logExtension, const std::string &detail) const throw(); - void writeBurstLogFile(const std::string &buffer) throw(); - bool burstLogEnabled() const throw() { return (((a_burstLogFile == "") || (a_burstLogFile == "null")) ? false : true); } - int clearBurst() throw(); // returns removed - int loadBurstMessage(const anna::DataBlock & db) throw(anna::RuntimeException); - void repeatBurst(bool repeat) throw() { a_burstRepeat = repeat; } - int startBurst(int initialLoad) throw(); // return processed on start, or -1 if burst list is empty, -2 if invalid initial load (0 or negative) - int pushBurst(int loadAmount) throw(); // returns pushed (perhaps is less than provided because of no repeat mode and burst list exhausted), or -1 if burst list is empty, -2 if invalid load (0 or negative) - int sendBurst(int loadAmount) throw(); // returns sent (burst always cycled using send), returns -1 if burst list is empty, -2 if invalid load (0 or negative) - int popBurst(int releaseAmount) throw(); // returns popped (perhaps is less than provided because of OTA request), or -1 if burst stopped - int stopBurst() throw(); // returns remaining on cycle, or -1 if burst already stopped - bool burstActive() const throw() { return a_burstActive; } - bool sendBurstMessage(bool anyway = false) throw(); - std::string lookBurst(int order = -1) const throw(); - std::string gotoBurst(int order) throw(); - - anna::xml::Node* asXML(anna::xml::Node* parent) const throw(); - std::string asXMLString() const throw(); + bool logEnabled() const { return (((a_logFile == "") || (a_logFile == "null")) ? false : true); } + void writeLogFile(const anna::DataBlock & db, const std::string &logExtension, const std::string &detail) const ; + void writeLogFile(const anna::diameter::codec::Message & decodedMessage, const std::string &logExtension, const std::string &detail) const ; + void writeBurstLogFile(const std::string &buffer) ; + bool burstLogEnabled() const { return (((a_burstLogFile == "") || (a_burstLogFile == "null")) ? false : true); } + int clearBurst() ; // returns removed + int loadBurstMessage(const anna::DataBlock & db) noexcept(false); + void repeatBurst(bool repeat) { a_burstRepeat = repeat; } + int startBurst(int initialLoad) ; // return processed on start, or -1 if burst list is empty, -2 if invalid initial load (0 or negative) + int pushBurst(int loadAmount) ; // returns pushed (perhaps is less than provided because of no repeat mode and burst list exhausted), or -1 if burst list is empty, -2 if invalid load (0 or negative) + int sendBurst(int loadAmount) ; // returns sent (burst always cycled using send), returns -1 if burst list is empty, -2 if invalid load (0 or negative) + int popBurst(int releaseAmount) ; // returns popped (perhaps is less than provided because of OTA request), or -1 if burst stopped + int stopBurst() ; // returns remaining on cycle, or -1 if burst already stopped + bool burstActive() const { return a_burstActive; } + bool sendBurstMessage(bool anyway = false) ; + std::string lookBurst(int order = -1) const ; + std::string gotoBurst(int order) ; + + anna::xml::Node* asXML(anna::xml::Node* parent) const ; + std::string asXMLString() const ; }; }