37using ColumnNames_t = std::vector<std::string>;
40class RCustomColumnBase;
62struct IsDataContainer {
66 static constexpr bool Test(
A *
pt,
A const *cpt =
nullptr,
decltype(
pt->begin()) * =
nullptr,
67 decltype(
pt->end()) * =
nullptr,
decltype(cpt->begin()) * =
nullptr,
68 decltype(cpt->end()) * =
nullptr,
typename A::iterator *
pi =
nullptr,
69 typename A::const_iterator *pci =
nullptr)
71 using It_t =
typename A::iterator;
72 using CIt_t =
typename A::const_iterator;
73 using V_t =
typename A::value_type;
74 return std::is_same<
decltype(
pt->begin()), It_t>::value && std::is_same<
decltype(
pt->end()), It_t>::value &&
75 std::is_same<
decltype(cpt->begin()), CIt_t>::value && std::is_same<
decltype(cpt->end()), CIt_t>::value &&
76 std::is_same<
decltype(**
pi), V_t &>::value && std::is_same<
decltype(**pci), V_t
const &>::value &&
77 !std::is_same<T, std::string>::value;
81 static constexpr bool Test(...)
86 static constexpr bool value = Test<Test_t>(
nullptr);
90struct IsDataContainer<std::vector<bool>> {
91 static constexpr bool value =
true;
96 static constexpr bool value =
true;
100struct IsDataContainer<std::span<T>> {
101 static constexpr bool value =
true;
106struct IsVector_t :
public std::false_type {};
108template <
typename T,
typename A>
109struct IsVector_t<std::vector<T, A>> :
public std::true_type {};
116 bool vector2rvec =
true);
123template <
bool MustRemove,
typename TypeList>
124struct RemoveFirstParameterIf {
128template <
typename TypeList>
129struct RemoveFirstParameterIf<true,
TypeList> {
130 using type = RemoveFirstParameter_t<TypeList>;
133template <
bool MustRemove,
typename TypeList>
136template <
bool MustRemove,
typename TypeList>
137struct RemoveFirstTwoParametersIf {
141template <
typename TypeList>
142struct RemoveFirstTwoParametersIf<true,
TypeList> {
147template <
bool MustRemove,
typename TypeList>
152struct IsRVec_t :
public std::false_type {};
161 using value_type =
typename T::value_type;
165struct ValueType<
T, false> {
166 using value_type =
T;
171 using value_type =
T;
178void Erase(
const T &that, std::vector<T> &
v)
180 v.erase(std::remove(
v.begin(),
v.end(), that),
v.end());
RDataSource defines an API that RDataFrame can use to read arbitrary data formats.
A simple, robust and fast interface to read values from ROOT columnar datasets such as TTree,...
A TTree represents a columnar dataset.
ROOT::VecOps::RVec< T > RVec
std::vector< std::string > ReplaceDotWithUnderscore(const std::vector< std::string > &columnNames)
Replace occurrences of '.
const std::type_info & TypeName2TypeID(const std::string &name)
Return the type_info associated to a name.
std::string ColumnName2ColumnTypeName(const std::string &colName, TTree *tree, RDataSource *ds, RCustomColumnBase *customColumn, bool vector2rvec)
Return a string containing the type of the given branch.
char TypeName2ROOTTypeName(const std::string &b)
Convert type name (e.g.
std::string TypeID2TypeName(const std::type_info &id)
Returns the name of a type starting from its type_info An empty string is returned in case of failure...
Long64_t InterpreterCalc(const std::string &code, const std::string &context)
void InterpreterDeclare(const std::string &code)
ROOT type_traits extensions.
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...
static constexpr double pi
Lightweight storage for a collection of types.