otsdaq  v2_05_02_indev
CgiDataUtilities.h
1 #ifndef ots_CgiDataUtilities_h
2 #define ots_CgiDataUtilities_h
3 
4 #pragma GCC diagnostic push
5 #pragma GCC diagnostic ignored "-Wunknown-pragmas"
6 #include <xgi/Method.h> //for cgicc::Cgicc
7 #pragma GCC diagnostic pop
8 #include <string>
9 
10 namespace ots
11 {
13 {
14  public:
15  CgiDataUtilities(){};
16  ~CgiDataUtilities(){};
17 
18  static std::string getOrPostData(cgicc::Cgicc& cgi, const std::string& needle);
19  static std::string postData(cgicc::Cgicc& cgi, const std::string& needle);
20  static std::string getData(cgicc::Cgicc& cgi, const std::string& needle);
21 
22  static int getOrPostDataAsInt(cgicc::Cgicc& cgi, const std::string& needle);
23  static int postDataAsInt(cgicc::Cgicc& cgi, const std::string& needle);
24  static int getDataAsInt(cgicc::Cgicc& cgi, const std::string& needle);
25 
26  // decodeURIComponent moved to StringMacros::
27  // static std::string decodeURIComponent(const std::string& data);
28 };
29 
30 } // namespace ots
31 
32 #endif // ots_CgiDataUtilities_h