connection_pool_fwd.hpp 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. //
  2. // Copyright (c) 2019-2025 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_DETAIL_CONNECTION_POOL_FWD_HPP
  8. #define BOOST_MYSQL_DETAIL_CONNECTION_POOL_FWD_HPP
  9. #include <boost/mysql/detail/config.hpp>
  10. #include <chrono>
  11. namespace boost {
  12. namespace mysql {
  13. class pooled_connection;
  14. class any_connection;
  15. namespace detail {
  16. template <class ConnectionType, class ClockType>
  17. class basic_connection_node;
  18. template <class ConnectionType, class ClockType, class ConnectionWrapper>
  19. class basic_pool_impl;
  20. using connection_node = basic_connection_node<any_connection, std::chrono::steady_clock>;
  21. using pool_impl = basic_pool_impl<any_connection, std::chrono::steady_clock, pooled_connection>;
  22. BOOST_MYSQL_DECL void return_connection(pool_impl& pool, connection_node& node, bool should_reset) noexcept;
  23. BOOST_MYSQL_DECL any_connection& get_connection(connection_node& node) noexcept;
  24. } // namespace detail
  25. } // namespace mysql
  26. } // namespace boost
  27. #endif