28 #ifndef CMR_REMOTERESOURCE_H_
29 #define CMR_REMOTERESOURCE_H_
31 #include <curl/curl.h>
32 #include <curl/easy.h>
38 #include "InternalErr.h"
52 std::string d_remoteResourceUrl;
66 char d_error_buffer[CURL_ERROR_SIZE];
72 std::string d_resourceCacheFileName;
75 std::vector<std::string> *d_request_headers;
78 std::vector<std::string> *d_response_headers;
81 std::map<std::string,std::string> *d_http_response_headers;
87 void writeResourceToFile(
int fd);
93 void ingest_http_headers_and_type();
97 d_fd(0), d_initialized(
false), d_curl(0), d_resourceCacheFileName(
""), d_request_headers(0), d_response_headers(
98 0), d_http_response_headers(0)
125 "RemoteHttpResource::getCacheFileName() - STATE ERROR: Remote Resource Has Not Been Retrieved.");
126 return d_resourceCacheFileName;
139 "RemoteHttpResource::getCacheFileName() - STATE ERROR: Remote Resource Has Not Been Retrieved.");
140 return d_response_headers;