Retrieves files from from a url. Caches a CURL handle so multiple accesses to a single url will keep connections open. More...
#include <retriever.h>
Public Member Functions | |
MemoryResource | get (const std::string &url) |
Get a file and store it in memory. | |
Retriever () | |
~Retriever () | |
Private Attributes | |
CURL * | curl_handle_ |
Retrieves files from from a url. Caches a CURL handle so multiple accesses to a single url will keep connections open.
Definition at line 66 of file retriever.h.
resource_retriever::Retriever::Retriever | ( | ) |
Definition at line 65 of file retriever.cpp.
resource_retriever::Retriever::~Retriever | ( | ) |
Definition at line 70 of file retriever.cpp.
MemoryResource resource_retriever::Retriever::get | ( | const std::string & | url | ) |
Get a file and store it in memory.
url | The url to retrieve. package://package/file will be turned into the correct file:// invocation |
resource_retriever::Exception | if anything goes wrong. |
Definition at line 94 of file retriever.cpp.
CURL* resource_retriever::Retriever::curl_handle_ [private] |
Definition at line 81 of file retriever.h.