|
| SubmitRankingRequest (uint32_t online_id, double scores, double max_scores, unsigned num_races, double raw_scores, double rating_deviation, uint64_t disconnects, const std::string &country_code) |
|
virtual void | afterOperation () |
| On a successful download converts the string into an XML tree.
|
|
| XMLRequest (int priority=1) |
| Creates a HTTP(S) request that will automatically parse the answer into a XML structure.
|
|
virtual | ~XMLRequest () |
| Cleans up the XML tree.
|
|
const XMLNode * | getXMLData () const |
| Get the downloaded XML tree.
|
|
const irr::core::stringw & | getInfo () const |
| Returns the additional information (or error message) contained in a finished request.
|
|
bool | isSuccess () const |
| Returns whether the request was successfully executed on the server.
|
|
| HTTPRequest (int priority=1) |
| Creates a HTTP(S) request that will have a raw string as result.
|
|
| HTTPRequest (const std::string &filename, int priority=1) |
| This constructor configures this request to save the data in a flie.
|
|
| HTTPRequest (const char *const filename, int priority=1) |
| Char * needs a separate constructor, otherwise it will be considered to be the no-filename constructor (char* -> bool).
|
|
virtual bool | isAllowedToAdd () const OVERRIDE |
| Checks the request if it has enough (correct) information to be executed (and thus allowed to add to the queue).
|
|
void | setApiURL (const std::string &url, const std::string &action) |
| A handy shortcut that appends the given path to the URL of the mutiplayer server.
|
|
void | setAddonsURL (const std::string &path) |
| A handy shortcut that appends the given path to the URL of the addons server.
|
|
virtual bool | hadDownloadError () const |
| Returns true if there was an error downloading the file.
|
|
void | setDownloadAssetsRequest (bool val) |
|
const char * | getDownloadErrorMessage () const |
| Returns the curl error message if an error has occurred.
|
|
const std::string & | getData () const |
| Returns the downloaded string.
|
|
void | addParameter (const std::string &name, const std::string &value) |
| Sets a parameter to 'value' (std::string).
|
|
void | addParameter (const std::string &name, const irr::core::stringw &value) |
| Sets a parameter to 'value' (stringw).
|
|
template<typename T > |
void | addParameter (const std::string &name, const T &value) |
| Sets a parameter to 'value' (arbitrary types).
|
|
float | getProgress () const |
| Returns the current progress.
|
|
void | setProgress (float f) |
| Sets the current progress.
|
|
const std::string & | getURL () const |
|
void | setURL (const std::string &url) |
| Sets the URL for this request.
|
|
const std::string & | getFileName () const |
|
double | getTotalSize () const |
|
void | setTotalSize (double d) |
|
| Request (int priority, int type) |
| Creates a request that can be handled by the RequestManager.
|
|
void | execute () |
| Executes the request.
|
|
void | executeNow () |
| Executes the request now, i.e.
|
|
void | queue () |
| Inserts this request into the RequestManager's queue for executing.
|
|
virtual void | callback () |
| Executed when a request has finished.
|
|
int | getType () const |
| Returns the type of the request.
|
|
int | getPriority () const |
| Returns the priority of this request.
|
|
void | cancel () |
| Signals that this request should be canceled.
|
|
bool | isCancelled () const |
| Returns if this request is to be canceled.
|
|
bool | isAbortable () const |
| Returns if this request can be aborted.
|
|
void | setAbortable (bool b) |
| Sets if this request is abortable or not.
|
|
void | setBusy () |
| Sets the request state to busy.
|
|
void | setExecuted () |
| Sets the request to be completed.
|
|
void | setDone () |
| Should only be called by the manager.
|
|
bool | isDone () const |
| Returns if this request is done.
|
|
bool | isPreparing () const |
| Returns if this request is being prepared.
|
|
bool | isBusy () const |
| Returns if this request is busy.
|
|
bool | hasBeenExecuted () const |
| Checks if the request has completed or done (i.e.
|
|
virtual bool | isAllowedToAdd () const |
| Virtual method to check if a request has initialized all needed members to a valid value.
|
|
|
enum | RequestType { RT_QUIT = 1
} |
|
virtual void | afterOperation () OVERRIDE |
| On a successful download converts the string into an XML tree.
|
|
virtual void | prepareOperation () OVERRIDE |
| Sets up the curl data structures.
|
|
virtual void | operation () OVERRIDE |
| The actual curl download happens here.
|
|
virtual void | afterOperation () OVERRIDE |
| Cleanup once the download is finished.
|
|
void | init () |
| Initialises all member variables.
|
|
virtual void | operation () |
| The actual operation to be executed.
|
|
virtual void | prepareOperation () |
| Virtual function to be called before an operation.
|
|
virtual void | afterOperation () |
| Virtual function to be called after an operation.
|
|
static int | progressDownload (void *clientp, progress_t dltotal, progress_t dlnow, progress_t ultotal, progress_t ulnow) |
| Callback function from curl: inform about progress.
|
|
static size_t | writeCallback (void *contents, size_t size, size_t nmemb, void *userp) |
| Callback from curl.
|
|
irr::core::stringw | m_info |
| Additional info contained the downloaded data (or an error message if a problem occurred).
|
|
bool | m_success |
| True if the request was successful executed on the server.
|
|
std::string | m_filename |
| Contains a filename if the data should be saved into a file instead of being kept in in memory.
|
|
bool | m_disable_sending_log |
|
bool | m_download_assets_request = false |
|
Synchronised< bool > | m_cancel |
| Cancel this request if it is active.
|
|
Synchronised< bool > | m_is_abortable |
| If this request can be aborted (at the end of STK).
|
|
Synchronised< State > | m_state |
| Set to though if the reply of the request is in and callbacks are executed.
|
|