10Duke Enterprise C++ SDK
Loading...
Searching...
No Matches
ServiceConfiguration.h
1#ifndef TENDUKE_SERVICECONFIGURATION_H
2#define TENDUKE_SERVICECONFIGURATION_H
3
4#include "http/HTTPRequest.h"
5
6#include <chrono>
7#include <cstddef>
8
9namespace tenduke {
10
15{
16public:
26 const std::chrono::milliseconds &networkTimeout = std::chrono::milliseconds(::tenduke::http::DEFAULT_TIMEOUT_MS)
27 , const std::chrono::milliseconds &networkConnectionTimeout = std::chrono::seconds(60)
32 {}
33
34public:
36 const std::chrono::milliseconds networkConnectionTimeout;
38 const std::chrono::milliseconds networkTimeout;
40 const std::size_t maxResponseBodySize;
41};
42
43}
44
45#endif //TENDUKE_SERVICECONFIGURATION_H
ServiceConfiguration(const std::chrono::milliseconds &networkTimeout=std::chrono::milliseconds(::tenduke::http::DEFAULT_TIMEOUT_MS), const std::chrono::milliseconds &networkConnectionTimeout=std::chrono::seconds(60), const std::size_t maxResponseBodySize=::tenduke::http::DEFAULT_MAX_RESPONSE_BODY_SIZE)
Constructs new instance.
Definition ServiceConfiguration.h:25
const std::chrono::milliseconds networkTimeout
Total timeout of a network request, zero for no timeout.
Definition ServiceConfiguration.h:38
const std::size_t maxResponseBodySize
Maximum size of a network response body in bytes.
Definition ServiceConfiguration.h:40
const std::chrono::milliseconds networkConnectionTimeout
Network connection timeout, zero for the default of the HTTP library.
Definition ServiceConfiguration.h:36
ServiceConfiguration(const std::chrono::milliseconds &networkTimeout=std::chrono::milliseconds(::tenduke::http::DEFAULT_TIMEOUT_MS), const std::chrono::milliseconds &networkConnectionTimeout=std::chrono::seconds(60), const std::size_t maxResponseBodySize=::tenduke::http::DEFAULT_MAX_RESPONSE_BODY_SIZE)
Constructs new instance.
Definition ServiceConfiguration.h:25
const std::size_t DEFAULT_MAX_RESPONSE_BODY_SIZE
Default maximum size of a response body in bytes (10 MiB).
Definition HTTPRequest.h:21
const long DEFAULT_TIMEOUT_MS
Default total time out in milliseconds.
Definition HTTPRequest.h:18
Root for classes, functions and globals of 10Duke C++ Client.
Definition APIRequest.h:4