1 // ANNA - Anna is Not Nothingness Anymore //
3 // (c) Copyright 2005-2015 Eduardo Ramos Testillano & Francisco Ruiz Rayo //
5 // See project site at http://redmine.teslayout.com/projects/anna-suite //
6 // See accompanying file LICENSE or copy at http://www.teslayout.com/projects/public/anna.LICENSE //
9 #ifndef example_diameter_launcher_MyLocalServer_hpp
10 #define example_diameter_launcher_MyLocalServer_hpp
13 #include <anna/diameter.comm/LocalServer.hpp>
16 #include "ProgrammedAnswers.hpp"
26 class MyLocalServer : public anna::diameter::comm::LocalServer {
28 anna::diameter::codec::Engine * a_codecEngine; // for automatic answers (failed-avp), write logs, etc.
30 void eventResponse(const anna::diameter::comm::Response&) throw(anna::RuntimeException);
31 void eventRequest(anna::diameter::comm::ServerSession *, const anna::DataBlock&) throw(anna::RuntimeException);
32 void eventUnknownResponse(anna::diameter::comm::ServerSession *, const anna::DataBlock&) throw(anna::RuntimeException);
33 void eventDPA(anna::diameter::comm::ServerSession *, const anna::DataBlock&) throw(anna::RuntimeException);
37 ProgrammedAnswers a_reactingAnswers;
38 void setCodecEngine(anna::diameter::codec::Engine *codecEngine) throw() { a_codecEngine = codecEngine; a_reactingAnswers.setCodecEngine(codecEngine); }
39 ProgrammedAnswers *getReactingAnswers() throw() { return (ProgrammedAnswers *)&a_reactingAnswers; }