| 398 | //-------------------------------------- |
| 399 | |
| 400 | void HTTPObject::setOption(const std::string &option, const std::string &value) |
| 401 | { |
| 402 | if (option == "verbose") { /* opt = new curlpp::options::Verbose(StringMath::scan<bool>(value)); */ } |
| 403 | else if (option == "user-agent") { curl_easy_setopt(mCurl, CURLOPT_USERAGENT, value.c_str()); } |
| 404 | else if (option == "cookie") { curl_easy_setopt(mCurl, CURLOPT_COOKIE, value.c_str()); } |
| 405 | else if (option == "verify-peer") { curl_easy_setopt(mCurl, CURLOPT_SSL_VERIFYPEER, value == "true"); } |
| 406 | else { |
| 407 | Con::errorf("HTTPObject::setOption unknown option %s", option.c_str()); |
| 408 | } |
| 409 | } |
| 410 | |
| 411 | void HTTPObject::setDownloadPath(const std::string &path) |
| 412 | { |
no test coverage detected