|
ATLAS Offline Software
|
Go to the documentation of this file.
9 #ifndef EVENT_LOOP__OUTPUT_STREAM_DATA_H
10 #define EVENT_LOOP__OUTPUT_STREAM_DATA_H
17 #include <unordered_map>
72 TFile *
file ()
const noexcept;
114 void addOutput (std::unique_ptr<TObject> outputObject);
125 void addClone (
const TObject& prototypeObject);
void addOutput(std::unique_ptr< TObject > outputObject)
add the given output object to this stream
all data needed to manage a given output stream
TFile * file() const noexcept
the file we are writing to
std::vector< std::unique_ptr< TObject > > m_output
the list of objects to write out at the end of job
TObject * getOutputHist(const std::string &name) const noexcept
get the output histogram with the given name, or nullptr if there is no histogam with such a name
TTree * getOutputTree(const std::string &name) const noexcept
get the output tree with the given name, or nullptr if there is no tree with such a name
void addClone(const TObject &prototypeObject)
add a clone of the given object to the output
void close()
close this file
std::unique_ptr< SH::DiskWriter > m_writer
the writer we use
std::unordered_map< std::string, TTree * > m_outputTreeMap
the output tree map
std::string finalFileName() const
the final path of the file created
::StatusCode StatusCode
StatusCode definition for legacy code.
This module defines the arguments passed from the BATCH driver to the BATCH worker.
void testInvariant() const
test the invariant of this object
TDirectory * makeDirectoryFor(std::string &name)
make the directory for the object of the given name
std::unordered_map< std::string, TObject * > m_outputHistMap
the output histogram map
void saveOutput()
write the list of output objects to disk and clear it
OutputStreamData(const std::string &val_fileName, const std::string &mode)
open the given file and create an output stream for it