|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef XAODDATASOURCE_RDATASOURCE_H
6 #define XAODDATASOURCE_RDATASOURCE_H
15 #include <ROOT/RDataSource.hxx>
16 #include <ROOT/RStringView.hxx>
22 #include <unordered_map>
40 std::string_view
treeName =
"CollectionTree" );
43 std::string_view
treeName =
"CollectionTree" );
54 virtual void SetNSlots(
unsigned int slots )
override final;
56 #if ROOT_VERSION_CODE < ROOT_VERSION(6,28,0)
57 virtual void Initialise() override final;
63 InitSlot(
unsigned int slot, ULong64_t firstEntry )
override final;
65 #if ROOT_VERSION_CODE < ROOT_VERSION(6,28,0)
66 virtual void FinaliseSlot(
unsigned int slot )
override final;
69 virtual void Finalise() override final;
71 virtual void FinalizeSlot(
unsigned int slot )
override final;
74 virtual void Finalize() override final;
78 virtual const std::vector< std::string >&
90 SetEntry(
unsigned int slot, ULong64_t
entry ) override final;
103 const std::type_info& typeInfo ) override final;
153 #endif // XAODDATASOURCE_RDATASOURCE_H
virtual void FinalizeSlot(unsigned int slot) override final
Close the input file reading in one of the slots/threads.
RDataSource(std::string_view fileNameGlob, std::string_view treeName="CollectionTree")
Constructor with the file name pattern.
std::vector< std::unique_ptr< TStore > > m_stores
In-memory whiteboards used during the event loop.
Bool_t isVerboseOutput() const
Check whether verbose output is set up to be printed.
virtual EntryRanges_t GetEntryRanges() override final
Get the entry ranges in the input file(s)
std::vector< std::string > m_fileNames
Files to read.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
std::vector< std::unique_ptr< TChain > > m_chains
Chains used in the file I/O.
std::unordered_map< std::string, std::string > m_classNameMap
The object name -> class name map.
bool const RAWDATA *ch2 const
std::vector< std::unique_ptr< RDataSourceEvent > > m_events
Event objects performing the file I/O.
EntryRanges_t m_entryRanges
Optimal entry ranges to split the processing into.
Bool_t m_verboseOutput
Whether verbose output should be printed or not.
Data source for xAOD input files.
std::vector< std::string > m_columnNames
Names of the columns/objects on the input.
virtual Record_t GetColumnReadersImpl(std::string_view column, const std::type_info &typeInfo) override final
Return the type-erased vector of pointers to pointers to column values.
virtual void Finalize() override final
Finalize the data source, after the event loop.
virtual void Initialize() override final
Initialize the data source, before the start of the event loop.
virtual bool HasColumn(std::string_view name) const override final
Check if the dataset has a certain column/object.
std::vector< std::pair< ULong64_t, ULong64_t > > EntryRanges_t
Type describing the entry ranges of the input file(s)
void readInputMetadata()
Fill the metadata variables.
void setVerboseOutput(Bool_t value=kTRUE)
Set whether verbose output should be printed (for debugging)
struct _SetEntry SetEntry
Internal structure representing an entry in the set.
std::string m_treeName
Name of the event tree in the input files.
A relatively simple transient store for objects created in analysis.
virtual void InitSlot(unsigned int slot, ULong64_t firstEntry) override final
Initialize one of the slots/threads.
~RDataSource()
Destructor.
Extension to xAOD::TEvent, used by xAOD::RDataSource.
virtual const std::vector< std::string > & GetColumnNames() const override final
Get the column/object names for the input file(s)
virtual std::string GetTypeName(std::string_view column) const override final
Get the type name of a given column/object.
virtual void SetNSlots(unsigned int slots) override final
Set the number of threads/slots that the data source should use.