21 #ifndef otbCurlHelper_h
22 #define otbCurlHelper_h
53 bool TestUrlAvailability(
const std::string& url)
const override;
55 bool IsCurlReturnHttpError(
const std::string& url)
const;
57 int RetrieveFile(
const std::ostringstream& urlStream, std::string filename)
const override;
59 int RetrieveFile(
const std::string& urlString, std::string filename)
const override;
61 int RetrieveUrlInMemory(
const std::string& urlString, std::string& output)
const override;
63 int RetrieveFileMulti(
const std::vector<std::string>& listURLs,
const std::vector<std::string>& listFiles,
int maxConnect)
const override;
65 itkGetMacro(Timeout,
long int);
67 itkSetMacro(Timeout,
long int);
72 "Mozilla/5.0 (Windows; U; Windows NT 6.0; en-GB; rv:1.8.1.11) "
73 "Gecko/20071127 Firefox/2.0.0.11"),
83 void operator=(
const Self&) =
delete;
88 static size_t CallbackWriteDataToFile(
void* ptr,
size_t size,
size_t nmemb,
void* data);
90 static size_t CallbackWriteDataToStringStream(
void* ptr,
size_t size,
size_t nmemb,
void* data);
92 static size_t CallbackWriteDataDummy(
void* ptr,
size_t size,
size_t nmemb,
void* data);