|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef TRIGCOMBINEDEVENT_TRIGCOMPOSITE_H
6 #define TRIGCOMBINEDEVENT_TRIGCOMPOSITE_H
13 #include "GaudiKernel/ClassID.h"
15 #include "GaudiKernel/MsgStream.h"
42 inline const std::string&
name()
const {
return m_name; }
56 void setFormat(
const std::vector<std::string>&
keys,
bool mustBeSet=
false);
109 std::vector<TrigFeatureLink>
getObjectsByType(
const std::string& keypart=
"")
const;
150 return detailsMap<T>();
178 std::map<std::string, TrigFeatureLink >
m_links;
203 const std::map<std::string, T>&
detailsMap()
const;
227 std::vector<TrigFeatureLink>
result;
228 for ( std::map<std::string, TrigFeatureLink>::const_iterator
i =
m_links.begin();
i !=
m_links.end(); ++
i ) {
229 if (
i->second.clid() == requested_clid and
i->first.find(keypart) != std::string::npos)
243 #endif // __TrigComposite_h__
MustSetList m_v_stringsToBeSet
const T & getDetail(const std::string &key) const
return the value of the detail, if the key is absent the default is returned
MustSetList m_linksToBeSet
std::map< std::string, std::vector< int > > m_v_ints
void addDetail(const std::string &key, const T &value=T())
adds the value user the key, if they detail under that key already exists the exception is thrown If ...
bool hasObject(const std::string &key) const
checks if the object has link to the object under the key
std::set< std::string > MustSetList
const T & specimen() const
std::vector< ALFA_RawDataCollection_p1 > t1
bool isFormatLocked() const
return true if the format can not be further changed (no addDetail can be called)
void lockFormat()
makes further addition of the details impossible
bool isValid() const
Checks the validity of the format, i.e.
const TrigFeatureLink & getObject(const std::string &key) const
returns
static const CLID & ID()
the CLID of T
std::map< std::string, T > & detailsMap()
std::map< std::string, int > m_ints
void setObject(const std::string &key, TrigFeatureLink link)
sets the link
std::map< std::string, std::vector< std::string > > m_v_strings
void unlockFormat()
makes addition of further details possible again
~TrigComposite()
Destructor, does nothing special in fact, no links are touched.
std::map< std::string, std::vector< float > > m_v_floats
MustSetList m_v_floatsToBeSet
MustSetList m_stringsToBeSet
uint32_t CLID
The Class ID type.
std::map< std::string, float > m_floats
void setFormat(const std::vector< std::string > &keys, bool mustBeSet=false)
defines the content (details which must to be stored) The method can be used to enforce certain conte...
MustSetList m_floatsToBeSet
std::map< std::string, TrigFeatureLink > m_links
TrigComposite()
Deafault constructor, should not be normally used, needed by the persistency layer.
std::vector< TrigFeatureLink > getObjectsByType(const std::string &keypart="") const
get all links which point to objects of given type
void eraseDetail(const std::string &key)
erases the detail if it existed If the details inder that key did not exist, no action is performed.
std::vector< ALFA_RawDataContainer_p1 > t2
const std::string & name() const
const std::map< std::string, T > & allDetails() const
return the map of all the details Notie that the non-const version is not provided because it would a...
#define CLASS_DEF(NAME, CID, VERSION)
associate a clid and a version to a type eg
void addObject(const std::string &key, TrigFeatureLink link)
adds the link
void setDetail(const std::string &key, const T &value)
sets the value user the key, if they detail under that key already exists it's value is overwritten,...
MustSetList m_v_intsToBeSet
std::map< std::string, std::string > m_strings
MustSetList & detailsMustSetList()
macros to associate a CLID to a type
bool hasDetail(const std::string &key) const
Checks if the object contains detail of the type T No verification is made if it is set.
MustSetList m_intsToBeSet
void mustSet(const std::string &key)
MsgStream & operator<<(MsgStream &m, const TrigComposite &d)
Prints the content of the object.