This commit is contained in:
2024-06-14 12:25:28 +03:00
parent 849c68a060
commit daf4e1eab9
2 changed files with 130 additions and 89 deletions

View File

@@ -23,6 +23,8 @@ protected:
ImplT _impl;
public:
using impl_t = ImplT;
using typename ImplT::endpoint_t;
using timeout_clock_t = std::chrono::steady_clock;
@@ -45,9 +47,12 @@ public:
/* asynchronuos operations */
// open connection
auto asyncConnect(const endpoint_t& end_point, const timeout_drtn_t& timeout = defaultConnectTimeout)
template <typename... ArgTs>
auto asyncConnect(const endpoint_t& end_point,
const timeout_drtn_t& timeout = defaultConnectTimeout,
ArgTs&&... args)
{
return _impl.asyncConnect(end_point, timeout);
return _impl.asyncConnect(end_point, timeout, std::forward<ArgTs>(args)...);
}
@@ -94,4 +99,15 @@ public:
};
namespace traits
{
// template <typename T>
// concept adc_netservice_c = requires {
// typename T::impl_t;
// std::derived_from<AdcNetService<typename T::impl_t>>;
// };
} // namespace traits
} // namespace adc