#include <anna/time/functions.hpp>
#include <anna/time/Date.hpp>
-#include <anna/diameter/codec/tme/Engine.hpp>
+#include <anna/diameter/codec/Engine.hpp>
#include <anna/diameter/codec/tme/Message.hpp>
anna::time::functions::setControlPoint(); // start control point (application lifetime)
anna::diameter::stack::Engine & stackEngine = anna::diameter::stack::Engine::instantiate();
anna::diameter::stack::Dictionary *dictionary;
- anna::diameter::codec::tme::Engine *codecEngine = new anna::diameter::codec::tme::Engine();
std::string exec = argv[0];
std::string param = argv[1] ? argv[1] : "";
dictionary->load(param + "/avps_tgpp.xml");
dictionary->load(param + "/avps_tme.xml");
dictionary->load(param + "/commands_dccaOCS-CS_HuaweiNGIN_de-es.xml");
- codecEngine->setDictionary(dictionary);
// Trace:
LOGINFORMATION(Logger::information(stackEngine.asString(), ANNA_FILE_LOCATION));
LOGDEBUG(Logger::debug(dictionary->asString(), ANNA_FILE_LOCATION));
- LOGDEBUG(Logger::debug(codecEngine->asString(), ANNA_FILE_LOCATION));
} catch(anna::RuntimeException &ex) {
ex.trace();
std::cout << ex.getText() << std::endl;
}
// Build CCA
- tmeMessage cca;
+ anna::diameter::codec::Engine *codecEngine = new anna::diameter::codec::Engine("TME Engine", dictionary);
+ LOGDEBUG(Logger::debug(codecEngine->asString(), ANNA_FILE_LOCATION));
+ tmeMessage cca(codecEngine);
cca.setId("Credit-Control-Answer");
tmeAvp *sid = (tmeAvp*)cca.addAvp("Session-Id");
tmeAvp *ohst = (tmeAvp*)cca.addAvp("Origin-Host");