IDS peak genericC++ v1.15.0
Loading...
Searching...
No Matches
peak_timeout.hpp
Go to the documentation of this file.
1
10
11#pragma once
12
14
15#include <chrono>
16#include <cstdint>
17
18namespace peak
19{
20namespace core
21{
22
32{
33public:
39 static constexpr uint64_t INFINITE_TIMEOUT = PEAK_INFINITE_TIMEOUT;
40
41 Timeout(uint64_t timeout = 0) noexcept
42 : m_timeout(timeout)
43 {}
44
45 Timeout(std::chrono::milliseconds timeout) noexcept
46 : m_timeout(timeout)
47 {}
48
49 operator uint64_t() const
50 {
51 return static_cast<uint64_t>(m_timeout.count());
52 }
53
54private:
55 std::chrono::milliseconds m_timeout;
56};
57
58} /* namespace core */
59} /* namespace peak */
Timeout(uint64_t timeout=0) noexcept
Definition peak_timeout.hpp:41
static constexpr uint64_t INFINITE_TIMEOUT
The constant defining an infinite timeout.
Definition peak_timeout.hpp:39
Timeout(std::chrono::milliseconds timeout) noexcept
Definition peak_timeout.hpp:45
The "core" namespace contains the direct GenAPI and GenTL wrapper.
Definition peak_buffer.hpp:34
The "peak" namespace directly contains convenience functionality like the DeviceManager as well as th...
Definition peak_dynamic_loader.h:33
static const uint64_t PEAK_INFINITE_TIMEOUT
Definition peak_backend.h:361