7#ifndef TRIGNAVSTRUCTURE_TRIGHOLDERSTRUCTURE
8#define TRIGNAVSTRUCTURE_TRIGHOLDERSTRUCTURE
29 template<
typename HolderType = BaseHolder>
34 template<
typename HolderType = BaseHolder>
39 template<
typename HolderType = BaseHolder>
41 std::vector<HolderType*>
result;
43 for(
auto& index_holder : clid_indexmap.second){
50 template<
typename HolderType = BaseHolder>
52 std::vector<HolderType*>
result;
56 for(
auto& index_holder : lookup_it->second){
65 if (stiOrLabel.index() == 0){
66 return std::get<sub_index_type>(stiOrLabel);
72 auto it = lookup_it->second.find(std::get<std::string>(stiOrLabel));
80 if (stiOrLabel.index() == 1){
81 return std::get<std::string>(stiOrLabel);
84 std::string invalid_label =
"inavalid_label";
89 auto it = lookup_it->second.find(std::get<sub_index_type>(stiOrLabel));
90 if(it==lookup_it->second.end())
return invalid_label;
105 auto cast_holder =
dynamic_cast<T*
>(holder);
BaseHolder * getBaseHolder(class_id_type clid, sub_index_type sti) const
std::map< sub_index_type, std::string > SubIndexToLabelMap
std::string getLabel(class_id_type clid, const index_or_label_type &stiOrLabel) const
std::vector< HolderType * > getAllHolders() const
HolderType * getHolderForFeature(const TriggerElement::FeatureAccessHelper &fea) const
sub_index_type getSubTypeIndex(class_id_type clid, const index_or_label_type &stiOrLabel) const
std::map< class_id_type, SubIndexToLabelMap > m_lookupLabels
T * getCastHolder(BaseHolder *holder) const
std::vector< HolderType * > getHoldersOfClid(class_id_type clid) const
HolderType * getHolder(class_id_type clid, const std::variant< sub_index_type, std::string > &stiOrLabel) const
std::map< class_id_type, LabelToSubIndexMap > m_lookupSubIndex
std::map< std::string, sub_index_type > LabelToSubIndexMap
bool registerHolder(const std::shared_ptr< BaseHolder > &holder)
std::map< sub_index_type, std::shared_ptr< BaseHolder > > IndexToHolderMap
std::map< class_id_type, IndexToHolderMap > m_holderByClidAndIndex
the FeatureAccessHelper is a class used to keep track of features attached to this TE.
const ObjectIndex & getIndex() const
index in the external ojects array
class_id_type getCLID() const
Class ID of object.
sub_index_type subTypeIndex() const
to get collection index
Class mimicking the AthMessaging class from the offline software.
It used to be useful piece of code for replacing actual SG with other store of similar functionality ...
std::variant< sub_index_type, std::string > index_or_label_type
static const index_type invalid_sub_index