ANNA Suite  2020b
Multipurpose development suite for Telco applications
functions.hpp
Go to the documentation of this file.
1 // ANNA - Anna is Not Nothingness Anymore //
2 // //
3 // (c) Copyright 2005-2015 Eduardo Ramos Testillano & Francisco Ruiz Rayo //
4 // //
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 //
7 
8 
9 #ifndef anna_diameter_helpers_base_functions_hpp
10 #define anna_diameter_helpers_base_functions_hpp
11 
12 
13 // Local
15 #include <anna/config/defines.hpp>
16 
18 
19 // STL
20 #include <string>
21 
22 //------------------------------------------------------------------------------
23 //---------------------------------------------------------------------- #define
24 //------------------------------------------------------------------------------
25 
26 namespace anna {
27 class DataBlock;
28 }
29 
30 
31 namespace anna {
32 
33 namespace diameter {
34 
35 namespace helpers {
36 
37 namespace base {
38 
39 
40 struct functions {
41 
42  // getters & helpers
43 
51  static U32 getResultCode(const anna::DataBlock &) noexcept(false);
52 
62  static void decodeSessionId(const std::string &sessionId, std::string &diameterIdentity, U32 &high, U32 &low, std::string &optional) noexcept(false);
63 
76  static std::string getSessionId(const anna::DataBlock &db, std::string &diameterIdentity, U32 &high, U32 &low, std::string &optional) noexcept(false);
77 
78 
86  static std::string getSessionId(const anna::DataBlock &db) noexcept(false) {
87  std::string dummy1, dummy4;
88  U32 dummy2, dummy3;
89  return (getSessionId(db, dummy1, dummy2, dummy3, dummy4));
90  }
91 
92 
100  static std::string getOriginHost(const anna::DataBlock &db) noexcept(false);
101 };
102 
103 
104 }
105 }
106 }
107 }
108 
109 
110 #endif
111 
static void decodeSessionId(const std::string &sessionId, std::string &diameterIdentity, U32 &high, U32 &low, std::string &optional) noexcept(false)
static std::string getSessionId(const anna::DataBlock &db) noexcept(false)
Definition: functions.hpp:86
static U32 getResultCode(const anna::DataBlock &) noexcept(false)
uint32_t U32
Definition: defines.hpp:75
Definition: functions.hpp:40
static std::string getOriginHost(const anna::DataBlock &db) noexcept(false)
static std::string getSessionId(const anna::DataBlock &db, std::string &diameterIdentity, U32 &high, U32 &low, std::string &optional) noexcept(false)
Definition: app.hpp:12
Definition: DataBlock.hpp:24