time.hpp 747 B

123456789101112131415161718192021222324252627282930
  1. //
  2. // Copyright (c) 2019-2024 Ruben Perez Hidalgo (rubenperez038 at gmail dot com)
  3. //
  4. // Distributed under the Boost Software License, Version 1.0. (See accompanying
  5. // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  6. //
  7. #ifndef BOOST_MYSQL_TIME_HPP
  8. #define BOOST_MYSQL_TIME_HPP
  9. #include <boost/config.hpp>
  10. #include <chrono>
  11. namespace boost {
  12. namespace mysql {
  13. /// Type representing MySQL `TIME` data type.
  14. using time = std::chrono::microseconds;
  15. /// The minimum allowed value for \ref time.
  16. BOOST_INLINE_CONSTEXPR time min_time = -std::chrono::hours(839);
  17. /// The maximum allowed value for \ref time.
  18. BOOST_INLINE_CONSTEXPR time max_time = std::chrono::hours(839);
  19. } // namespace mysql
  20. } // namespace boost
  21. #endif