Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
JSONReadRecorder.h
Go to the documentation of this file.
1/*
2 * Project: RooFit
3 * Authors:
4 * Jonas Rembser, CERN, Nov 2026
5 *
6 * Copyright (c) 2026, CERN
7 *
8 * Redistribution and use in source and binary forms,
9 * with or without modification, are permitted according to the terms
10 * listed in LICENSE (http://roofit.sourceforge.net/license.txt)
11 */
12
13#ifndef RooFit_Detail_JSONReadRecorder_h
14#define RooFit_Detail_JSONReadRecorder_h
15
17
18#include <set>
19#include <string>
20#include <vector>
21
22namespace RooFit {
23namespace Detail {
24
25/// Records which components of a JSON map are read while it is alive, through any node of the tree. Like that, the
26/// components that no importer understands can be reported without any change to the importers. Iterating over the
27/// components or writing the map counts as reading all of them.
29public:
30 explicit JSONReadRecorder(JSONNode const &node);
34
35 /// The components of the map that were not read.
36 std::vector<std::string> unreadComponents() const;
37
38 /// Called by the tree for every read of the component `key` of `value`, where nullptr means all components.
39 void record(void const *value, std::string const *key);
40
41private:
43 std::set<std::string> _read;
44 bool _readAll = false;
45};
46
47} // namespace Detail
48} // namespace RooFit
49
50#endif
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void value
Records which components of a JSON map are read while it is alive, through any node of the tree.
JSONReadRecorder & operator=(JSONReadRecorder const &)=delete
JSONReadRecorder(JSONReadRecorder const &)=delete
std::set< std::string > _read
void record(void const *value, std::string const *key)
Called by the tree for every read of the component key of value, where nullptr means all components.
JSONReadRecorder(JSONNode const &node)
std::vector< std::string > unreadComponents() const
The components of the map that were not read.
The namespace RooFit contains mostly switches that change the behaviour of functions of PDFs (or othe...
Definition CodegenImpl.h:73