LLVM: include/llvm/Debuginfod/HTTPClient.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15#ifndef LLVM_DEBUGINFOD_HTTPCLIENT_H
16#define LLVM_DEBUGINFOD_HTTPCLIENT_H
17
22
23#include
24
25namespace llvm {
26
28
29
37
39
40
41
42
44public:
45
47
48protected:
50};
51
52
54#ifdef LLVM_ENABLE_CURL
55 void *Curl = nullptr;
56#endif
57
58public:
61
63
64
66
67
69
70
72
73
74
76
77
78
79
81
82
84};
85
86}
87
88#endif
static GCRegistry::Add< ErlangGC > A("erlang", "erlang-compatible garbage collector")
static GCRegistry::Add< OcamlGC > B("ocaml", "ocaml 3.10-compatible GC")
This file defines the SmallString class.
This file defines the SmallVector class.
Lightweight error class with error context and mandatory checking.
static bool isAvailable()
Returns true only if LLVM has been compiled with a working HTTPClient.
static bool IsInitialized
Definition HTTPClient.h:62
unsigned responseCode()
Returns the last received response code or zero if none.
static void initialize()
Must be called at the beginning of a program, while it is a single thread.
Error perform(const HTTPRequest &Request, HTTPResponseHandler &Handler)
Performs the Request, passing response data to the Handler.
void setTimeout(std::chrono::milliseconds Timeout)
Sets the timeout for the entire request, in milliseconds.
static void cleanup()
Must be called at the end of a program, while it is a single thread.
A handler for state updates occurring while an HTTPRequest is performed.
Definition HTTPClient.h:43
virtual Error handleBodyChunk(StringRef BodyChunk)=0
Processes an additional chunk of bytes of the HTTP response body.
SmallString - A SmallString is just a SmallVector with methods and accessors that make it work better...
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small.
StringRef - Represent a constant reference to a string, i.e.
This is an optimization pass for GlobalISel generic memory operations.
bool operator==(const AddressRangeValuePair &LHS, const AddressRangeValuePair &RHS)
HTTPMethod
Definition HTTPClient.h:27
@ GET
Definition HTTPClient.h:27
@ Timeout
Reached timeout while waiting for the owner to release the lock.
A stateless description of an outbound HTTP request.
Definition HTTPClient.h:30
SmallVector< std::string, 0 > Headers
Definition HTTPClient.h:32
HTTPRequest(StringRef Url)
SmallString< 128 > Url
Definition HTTPClient.h:31
HTTPMethod Method
Definition HTTPClient.h:33
bool FollowRedirects
Definition HTTPClient.h:34