Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
RDFBookedCustomColumns.cxx
Go to the documentation of this file.
2 
3 namespace ROOT {
4 namespace Internal {
5 namespace RDF {
6 
7 bool RBookedCustomColumns::HasName(std::string_view name) const
8 {
9  const auto ccolnamesEnd = fCustomColumnsNames->end();
10  return ccolnamesEnd != std::find(fCustomColumnsNames->begin(), ccolnamesEnd, name);
11 }
12 
13 void RBookedCustomColumns::AddColumn(const std::shared_ptr<RDFDetail::RCustomColumnBase> &column,
14  std::string_view name)
15 {
16  auto newCols = std::make_shared<RCustomColumnBasePtrMap_t>(GetColumns());
17  (*newCols)[std::string(name)] = column;
18  fCustomColumns = newCols;
19 }
20 
21 void RBookedCustomColumns::AddName(std::string_view name)
22 {
23  auto newColsNames = std::make_shared<ColumnNames_t>(GetNames());
24  newColsNames->emplace_back(std::string(name));
25  fCustomColumnsNames = newColsNames;
26 }
27 
28 } // namespace RDF
29 } // namespace Internal
30 } // namespace ROOT