mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-22 17:47:59 +02:00
more testing
This commit is contained in:
@ -4,7 +4,7 @@
|
||||
namespace sls {
|
||||
|
||||
/**
|
||||
* Type trait to check if atemplate parameter is a std::chrono::duration
|
||||
* Type trait to check if a template parameter is a std::chrono::duration
|
||||
*/
|
||||
|
||||
template <typename T, typename _ = void>
|
||||
@ -22,6 +22,19 @@ struct is_duration<T,
|
||||
decltype(std::declval<T>().zero())>,
|
||||
void>::type> : public std::true_type {};
|
||||
|
||||
/**
|
||||
* Has str method
|
||||
*/
|
||||
template <typename T, typename _ = void> struct has_str : std::false_type {};
|
||||
|
||||
template <typename... Ts> struct has_str_helper {};
|
||||
|
||||
template <typename T>
|
||||
struct has_str<T, typename std::conditional<
|
||||
false,
|
||||
has_str_helper<decltype(std::declval<T>().str())>,
|
||||
void>::type> : public std::true_type {};
|
||||
|
||||
/**
|
||||
* Type trait to evaluate if template parameter is
|
||||
* complying with a standard container
|
||||
|
Reference in New Issue
Block a user