|
cpp-ipfs-http-client
IPFS C++ client library
|
Convenience class for talking basic HTTP, implemented using CURL. More...
#include <ipfs/http/transport-curl.h>
Public Member Functions | |
| TransportCurl () | |
| Constructor. | |
| ~TransportCurl () | |
| Destructor. | |
| void | Fetch (const std::string &url, const std::vector< FileUpload > &files, std::iostream *response) override |
| Fetch the contents of a given URL. More... | |
| void | UrlEncode (const std::string &raw, std::string *encoded) override |
| URL encode a string. More... | |
| void | Test () |
| Test the internals that are hard to execute from the public API, like error handling of some exceptional cases. | |
Public Member Functions inherited from ipfs::http::Transport | |
| virtual | ~Transport () |
| Destructor. | |
Convenience class for talking basic HTTP, implemented using CURL.
|
overridevirtual |
Fetch the contents of a given URL.
If any files are provided in files, they are submitted using "Content-Type: multipart/form-data".
| std::exception | if any error occurs including erroneous HTTP status code |
| [in] | url | [in] URL to get. |
| [in] | files | [in] List of files to upload. |
| [out] | response | [out] Output to save the response body to. |
Implements ipfs::http::Transport.
|
overridevirtual |
URL encode a string.
| [in] | raw | [in] Input string to encode. |
| [out] | encoded | [out] URL encoded result. |
Implements ipfs::http::Transport.
1.8.17