X-Git-Url: http://www.project-moonshot.org/gitweb/?p=shibboleth%2Fcpp-xmltooling.git;a=blobdiff_plain;f=xmltooling%2Futil%2FCurlURLInputStream.h;h=a2be81e711705f9288f7b7fe76d41a425c15823b;hp=53b784f4cbd881cc142e5be02b21d34667d57cf5;hb=04302f1b6d2b753b00ff2bb99b20a89488f2f13d;hpb=cdd4b35118298bf5e0a16f3c5c4a31bf3d25271b diff --git a/xmltooling/util/CurlURLInputStream.h b/xmltooling/util/CurlURLInputStream.h index 53b784f..a2be81e 100644 --- a/xmltooling/util/CurlURLInputStream.h +++ b/xmltooling/util/CurlURLInputStream.h @@ -43,16 +43,18 @@ namespace xmltooling { /** * Constructor. * - * @param url the URL of the resource to fetch + * @param url the URL of the resource to fetch + * @param cacheTag optional pointer to string used for cache management */ - CurlURLInputStream(const char* url); + CurlURLInputStream(const char* url, std::string* cacheTag=NULL); /** * Constructor. * - * @param url the URL of the resource to fetch + * @param url the URL of the resource to fetch + * @param cacheTag optional pointer to string used for cache management */ - CurlURLInputStream(const XMLCh* url); + CurlURLInputStream(const XMLCh* url, std::string* cacheTag=NULL); /** * Constructor taking a DOM element supporting the following content: @@ -66,9 +68,10 @@ namespace xmltooling { *
<TransportOption provider="CURL" option="150">0</TransportOption>
* * - * @param e DOM to supply configuration + * @param e DOM to supply configuration + * @param cacheTag optional pointer to string used for cache management */ - CurlURLInputStream(const xercesc::DOMElement* e); + CurlURLInputStream(const xercesc::DOMElement* e, std::string* cacheTag=NULL); ~CurlURLInputStream(); @@ -101,11 +104,13 @@ namespace xmltooling { bool readMore(int *runningHandles); logging::Category& fLog; + std::string* fCacheTag; std::string fURL; std::vector fSavedOptions; CURLM* fMulti; CURL* fEasy; + struct curl_slist* fHeaders; unsigned long fTotalBytesRead; XMLByte* fWritePtr; @@ -120,6 +125,7 @@ namespace xmltooling { XMLByte* fBufferTailPtr; XMLCh* fContentType; + long fStatusCode; char fError[CURL_ERROR_SIZE]; };