Woman, Life, Freedom


Adaptive AUTOSAR
ARA public interface header documentation
curl_wrapper.h
1#ifndef CURL_WRAPPER_H
2#define CURL_WRAPPER_H
3
4#include <curl/curl.h>
5#include <string>
6
7namespace application
8{
9 namespace helper
10 {
13 {
14 private:
15 static size_t callback(void *buffer, size_t sz, size_t n, void *f);
16
17 CURL *mCurlHandler;
18 struct curl_slist *mHeaders;
19 std::string *mReceivedBuffer;
20
21 public:
26 CurlWrapper(std::string vccApiKey, std::string bearerToken);
27
28 CurlWrapper() = delete;
30
37 bool TryExecute(std::string url, std::string *response);
38 };
39 }
40}
41
42#endif
Minimalist C++ wrapper of easy (blocking interface) CURL library for RESTful communication.
Definition: curl_wrapper.h:13
bool TryExecute(std::string url, std::string *response)
Try to execute a RESTful GET request.
Definition: curl_wrapper.cpp:55
AUTOSAR application namespace.
Definition: diag_message_handler.cpp:5