CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CurlPoster.h
Go to the documentation of this file.
1 #ifndef CURLPOSTER_H
2 #define CURLPOSTER_H
3 
4 #include <sys/utsname.h>
5 #include <string>
6 
7 namespace evf {
8 
9 
10  class CurlPoster
11  {
12  public:
13 
15 
17  buf_=(struct utsname*)new char[sizeof(struct utsname)];
18  uname(buf_);
19  // check();
20  }
21  virtual ~CurlPoster(){delete [] buf_;}
22  bool check(int);
23  void postBinary(const unsigned char *, size_t, unsigned int
25  void postString(const char *, size_t, unsigned int
27  private:
28  void post(const unsigned char *, size_t, unsigned int, mode, const std::string&);
30  bool active_;
31  struct utsname* buf_;
33  };
34 
35 } // evf
36 
37 #endif
bool check(int)
Definition: CurlPoster.cc:125
struct utsname * buf_
Definition: CurlPoster.h:31
void postString(const char *, size_t, unsigned int, mode, const std::string &=standard_post_method_)
Definition: CurlPoster.cc:112
void postBinary(const unsigned char *, size_t, unsigned int, const std::string &=standard_post_method_)
Definition: CurlPoster.cc:118
virtual ~CurlPoster()
Definition: CurlPoster.h:21
CurlPoster(const std::string &url)
Definition: CurlPoster.h:16
static const std::string standard_post_method_
Definition: CurlPoster.h:32
std::string url_
Definition: CurlPoster.h:29
void post(const unsigned char *, size_t, unsigned int, mode, const std::string &)
Definition: CurlPoster.cc:18