Hot Door CORE  0.7.0
Adobe® Illustrator® Plug-in Library
hdicoreInternetPOST.h
Go to the documentation of this file.
1 
7 #ifndef __HDI_CORE_INTERNET_POST__
8 #define __HDI_CORE_INTERNET_POST__
9 
10 #include <string>
11 
12 namespace hdi
13 {
14  namespace plugin
15  {
16  class InternetPOST;
17  }
18 
19  namespace core
20  {
21  class Callback;
22  class DictionaryPref;
23 
28  {
29  public:
46  const std::string& url_,
47  const DictionaryPref& data_,
48  const Callback& success_,
49  const Callback& failure_
50  );
51 
74  static InternetPOST* Async(
75  const std::string& url_,
76  const DictionaryPref& data_,
77  const Callback& success_,
78  const Callback& failure_
79  );
80 
86  virtual ~InternetPOST();
87 
95  virtual bool asynchronous() const;
96 
102  virtual void run();
103 
111  virtual bool running() const;
112 
126  virtual std::string content() const;
127 
138  virtual std::string error() const;
139 
140 
141  private:
145  plugin::InternetPOST* __impl;
146 
152  InternetPOST();
153 
159  InternetPOST(const InternetPOST&);
160 
166  InternetPOST& operator=(const InternetPOST&);
167  };
168  }
169 }
170 
171 #endif
172 // __HDI_CORE_INTERNET_POST__
virtual ~InternetPOST()
Destructs an InternetPOST object.
virtual bool asynchronous() const
Gets whether the target object is asynchronous (i.e. executes in a background thread) ...
Acts as a dictionary-style container to store any other persistent data types, including arrays and d...
Definition: hdicoreDictionaryPref.h:55
virtual bool running() const
Gets whether the POST request is currently running.
virtual std::string content() const
Gets the content acquired via the POST request.
Base class for templated __Callback class.
Definition: hdicoreCallback.h:67
virtual std::string error() const
Gets an error description if the POST request failed.
virtual void run()
Starts the POST request.
Definition: hdicoreaiArray.h:12
static InternetPOST * Async(const std::string &url_, const DictionaryPref &data_, const Callback &success_, const Callback &failure_)
Creates an asynchronous (non-blocking) InternetPOST object to perform HTTP(S) POST requests...
Allows for the creation of simple HTTP(S) POST clients to post to, and acquire data from...
Definition: hdicoreInternetPOST.h:27