File indexing completed on 2024-11-15 09:19:31
0001
0002
0003
0004
0005
0006
0007
0008 #ifndef BOOST_MYSQL_DETAIL_ACCESS_HPP
0009 #define BOOST_MYSQL_DETAIL_ACCESS_HPP
0010
0011 #include <utility>
0012
0013 namespace boost {
0014 namespace mysql {
0015 namespace detail {
0016
0017
0018
0019 struct access
0020 {
0021 template <class T>
0022 static decltype(std::declval<T>().impl_)& get_impl(T& obj) noexcept
0023 {
0024 return obj.impl_;
0025 }
0026
0027 template <class T>
0028 static const decltype(std::declval<T>().impl_)& get_impl(const T& obj) noexcept
0029 {
0030 return obj.impl_;
0031 }
0032
0033 template <class T, class... Args>
0034 static T construct(Args&&... args)
0035 {
0036 return T(std::forward<Args>(args)...);
0037 }
0038 };
0039
0040 }
0041 }
0042 }
0043
0044 #endif