5 #ifndef JODA_IVALUETESTHELPER_H
6 #define JODA_IVALUETESTHELPER_H
14 static void param(std::vector<V> &vec) {}
16 template <
typename V,
typename T1,
typename... Types>
17 static void param(std::vector<V> &vec, T1 &&t1, Types &&... args) {
18 vec.emplace_back(std::forward<T1 &&>(t1));
19 param(vec, std::forward<Types &&>(args)...);
22 static std::unique_ptr<joda::query::IValueProvider>
getNumVal(
double d) {
23 return std::make_unique<joda::query::DoubleProvider>(d);
26 static std::unique_ptr<joda::query::IValueProvider>
getNumVal(int64_t i) {
27 return std::make_unique<joda::query::Int64Provider>(i);
30 static std::unique_ptr<joda::query::IValueProvider>
getNumVal(u_int64_t i) {
31 return std::make_unique<joda::query::UInt64Provider>(i);
33 static std::unique_ptr<joda::query::IValueProvider>
getPointer(
35 return std::make_unique<joda::query::PointerProvider>(ptr);
39 return std::make_unique<joda::query::StringProvider>(str);
41 static std::unique_ptr<joda::query::IValueProvider>
getBoolVal(
bool b) {
42 return std::make_unique<joda::query::BoolProvider>(b);
Definition: IValueTestHelper.h:11
static std::unique_ptr< joda::query::IValueProvider > getPointer(std::string ptr)
Definition: IValueTestHelper.h:33
static std::unique_ptr< joda::query::IValueProvider > getNumVal(double d)
Definition: IValueTestHelper.h:22
static std::unique_ptr< joda::query::IValueProvider > getBoolVal(bool b)
Definition: IValueTestHelper.h:41
static void param(std::vector< V > &vec)
Definition: IValueTestHelper.h:14
static std::unique_ptr< joda::query::IValueProvider > getStringVal(std::string str)
Definition: IValueTestHelper.h:37
static void param(std::vector< V > &vec, T1 &&t1, Types &&... args)
Definition: IValueTestHelper.h:17
static std::unique_ptr< joda::query::IValueProvider > getNumVal(int64_t i)
Definition: IValueTestHelper.h:26
static std::unique_ptr< joda::query::IValueProvider > getNumVal(u_int64_t i)
Definition: IValueTestHelper.h:30