A struct used to store a version number, which can be checked and compared at compilation time.
More...
#include <BS_thread_pool.hpp>
|
| constexpr | version (const std::uint64_t major_, const std::uint64_t minor_, const std::uint64_t patch_) noexcept |
| std::string | to_string () const |
A struct used to store a version number, which can be checked and compared at compilation time.
◆ version()
| BS::version::version |
( |
const std::uint64_t | major_, |
|
|
const std::uint64_t | minor_, |
|
|
const std::uint64_t | patch_ ) |
|
inlineconstexprnoexcept |
std::uint64_t major
Definition BS_thread_pool.hpp:193
std::uint64_t minor
Definition BS_thread_pool.hpp:194
std::uint64_t patch
Definition BS_thread_pool.hpp:195
◆ to_string()
| std::string BS::version::to_string |
( |
| ) |
const |
|
inlinenodiscard |
183 {
184 return std::to_string(
major) +
'.' + std::to_string(
minor) +
'.' + std::to_string(
patch);
185 }
◆ operator!=
157 {
158 return !(lhs == rhs);
159 }
◆ operator<
162 {
163 return std::tuple(lhs.major, lhs.minor, lhs.patch) < std::tuple(rhs.major, rhs.minor, rhs.patch);
164 }
◆ operator<<
| std::ostream & operator<< |
( |
std::ostream & | stream, |
|
|
const version & | ver ) |
|
friend |
188 {
189 stream << ver.to_string();
190 return stream;
191 }
◆ operator<=
177 {
178 return !(lhs > rhs);
179 }
◆ operator==
152 {
153 return std::tuple(lhs.major, lhs.minor, lhs.patch) == std::tuple(rhs.major, rhs.minor, rhs.patch);
154 }
◆ operator>
172 {
173 return std::tuple(lhs.major, lhs.minor, lhs.patch) > std::tuple(rhs.major, rhs.minor, rhs.patch);
174 }
◆ operator>=
167 {
168 return !(lhs < rhs);
169 }
◆ major
| std::uint64_t BS::version::major |
◆ minor
| std::uint64_t BS::version::minor |
◆ patch
| std::uint64_t BS::version::patch |
The documentation for this struct was generated from the following file: