diff options
Diffstat (limited to 'vendor/jsoncons-0.104.0/jsoncons/version.hpp')
-rw-r--r-- | vendor/jsoncons-0.104.0/jsoncons/version.hpp | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/vendor/jsoncons-0.104.0/jsoncons/version.hpp b/vendor/jsoncons-0.104.0/jsoncons/version.hpp new file mode 100644 index 00000000..c7971685 --- /dev/null +++ b/vendor/jsoncons-0.104.0/jsoncons/version.hpp @@ -0,0 +1,50 @@ +// Copyright 2017 Daniel Parker +// Distributed under the Boost license, Version 1.0. +// (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See https://github.com/danielaparker/jsoncons for latest version + +#ifndef JSONCONS_VERSION_HPP +#define JSONCONS_VERSION_HPP + +#include <iostream> + +namespace jsoncons { + +struct versioning_info +{ + versioning_info(unsigned int major, + unsigned int minor, + unsigned int patch) + : major_(major), + minor_(minor), + patch_(patch) + {} + + unsigned int const major_; + unsigned int const minor_; + unsigned int const patch_; + + friend std::ostream& operator<<(std::ostream& os, const versioning_info& ver) + { + os << ver.major_ << '.' + << ver.minor_ << '.' + << ver.patch_; + return os; + } + + versioning_info(const versioning_info&) = default; + versioning_info() = delete; + versioning_info& operator=(const versioning_info&) = delete; +}; + +inline +versioning_info version() +{ + static versioning_info ver(0, 104, 0); + return ver; +} + +} + +#endif |