DSL
Classes | Macros | Typedefs | Enumerations | Functions
HTTP/FTP File Transfer

Classes

class  DSL_Download_Core
 
class  DSL_Download_NoCurl
 
struct  DSL_Download_CurlCallback
 
class  DSL_Download_Curl
 

Macros

#define DSL_SHOULDRETRY(x)   ((x < 5) & (x > 0))
 
#define DSL_CURL_API   DSL_API_VIS
 
#define DSL_CURL_API_CLASS   DSL_API_VIS
 
#define DSL_Download   DSL_Download_Curl
 

Typedefs

typedef bool(* DSL_Download_Callback) (uint64 got, uint64 fullsize, void *user_ptr)
 

Enumerations

enum  DSL_Download_Type { TD_HTTP , TD_HTTPS , TD_FTP }
 
enum  DSL_Download_Errors {
  TD_NO_ERROR , TD_FILE_ACCESS , TD_ERROR_CONNECTING , TD_INVALID_RESPONSE ,
  TD_ERROR_CREATING_SOCKET , TD_ERROR_INITIALIZING_LIB , TD_FILE_WRITE_ERROR , TD_INVALID_URL ,
  TD_CALLBACK_ABORT , TD_INVALID_PROTOCOL , TD_FILE_NOT_FOUND , TD_REDIRECT ,
  TD_TIMEOUT , TD_BAD_USER_PASS , TD_NUM_ERRORS
}
 

Functions

DSL_API_CLASS string curl_escapestring (string str)
 

Detailed Description

Typedef Documentation

◆ DSL_Download_Callback

typedef bool(* DSL_Download_Callback) (uint64 got, uint64 fullsize, void *user_ptr)

Progress callback for the download class.

Parameters
gotHow much of the fille has been received so far.
fullsizeThe full size of the file that is being downloaded. Will be 0 if the server doesn't give a Content-Length header.
Returns
true to continue download or false to abort.

Enumeration Type Documentation

◆ DSL_Download_Errors

Download error codes

◆ DSL_Download_Type

The type of download to perform.

Enumerator
TD_HTTP 

HTTP.

TD_HTTPS 

HTTPS (needs ENABLE_CURL defined)

TD_FTP 

FTP.