|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef SAMPLE_HANDLER_SAMPLE_HANDLER_HH
6 #define SAMPLE_HANDLER_SAMPLE_HANDLER_HH
470 const std::string&
value);
475 typedef std::vector<Sample*>::const_iterator
iterator;
JetConstituentVector::iterator iterator
void addWithPrefix(const SampleHandler &sh, const std::string &prefix)
add all samples from the given SampleHandler to this one, with prefix prepended to their name
Sample * findBySource(const std::string &name) const
find a sample by the name in the source sample handler
void add(std::unique_ptr< Sample > sample)
add a sample to the handler
void fetchDefaults(const SampleHandler &source)
fetch the meta-data for all that samples that don't have it in this sample.
std::vector< Sample * >::const_iterator iterator
the iterator to use
std::map< std::string, SH::SamplePtr >::iterator NamedIter
the iterator for m_named
Sample * at(std::size_t index) const
the sample with the given index
A class that manages a list of tags for identifying samples.
void add(Sample *sample)
add a sample to the handler
SampleHandler find(const std::string &tags) const
find all samples which have at least one of the given tags.
std::vector< SH::Sample * >::iterator SamplesMIter
the mutable iterator for m_samples
~SampleHandler()
standard destructor
void add(SamplePtr &sample)
add a sample to the handler
void updateLocation(const std::string &from, const std::string &to)
update all file references starting with from to to
SampleHandler & operator=(const SampleHandler &that)
standard assignment operator
SampleHandler find(const TagList &tags) const
find all samples which have at least one of the given tags.
void add(SamplePtr &&sample)
add a sample to the handler
std::vector< SH::Sample * > m_samples
the list of samples managed
iterator end() const
the end iterator to use
SampleHandler(const SampleHandler &that)
standard copy constructor
void printContent() const
print the debugging output to the screen
std::size_t size() const
the number of samples contained
void print() const
print the debugging output to the screen
void setMetaString(const std::string &pattern, const std::string &name, const std::string &value)
set the meta-data double with the given name for samples matching a pattern.
void save(const std::string &directory) const
save the list of samples to the given directory
const Sample * get(const std::string &name) const
get the sample with the given name
void setMetaDouble(const std::string &name, double value)
set the meta-data double with the given name for all samples.
void testInvariant() const
test the invariant of this object
std::vector< std::string > tags
void setMetaDouble(const std::string &pattern, const std::string &name, double value)
set the meta-data double with the given name for samples matching a pattern.
std::string dbg(const SampleHandler &obj, unsigned verbosity=0)
the debugging info of this object
a base class that manages a set of files belonging to a particular data set and the associated meta-d...
SampleHandler()
standard constructor
void load(const std::string &directory)
load all the samples from the given directory
bool check_complete(const SampleHandler &source) const
whether we have all samples from the source SampleHandler.
iterator begin() const
the begin iterator to use
A smart pointer class that holds a single Sample object.
void setMetaString(const std::string &name, const std::string &value)
set the meta-data string with the given name for all samples.
std::map< std::string, SH::SamplePtr > m_named
the list of samples by name
SampleHandler findByName(const std::string &pattern) const
find samples by pattern on the name
void add(const SampleHandler &sh)
add all samples from the given SampleHandler to this one
Sample * operator[](std::size_t index) const
the sample with the given index
void swap(SampleHandler &a, SampleHandler &b)
standard swap
std::map< std::string, SH::SamplePtr >::iterator NamedMIter
the mutable iterator for m_named
void remove(const std::string &name)
remove the given sample
A class that manages a list of Sample objects.
This module provides a lot of global definitions, forward declarations and includes that are used by ...
void remove(const Sample *sample)
remove the given sample
void fetch(const SampleHandler &source)
fetch the meta-data for all samples that are also in the source sample handler.
Sample * get(const std::string &name)
get the sample with the given name
std::vector< SH::Sample * >::const_iterator SamplesIter
the iterator for m_samples