CMS 3D CMS Logo

ThinnedAssociation.h
Go to the documentation of this file.
1 #ifndef DataFormats_Common_ThinnedAssociation_h
2 #define DataFormats_Common_ThinnedAssociation_h
3 
9 
10 #include <vector>
11 
12 namespace edm {
13 
15  public:
17 
20  std::vector<unsigned int> const& indexesIntoParent() const { return indexesIntoParent_; }
21 
22  bool hasParentIndex(unsigned int parentIndex, unsigned int& thinnedIndex) const;
23 
26  void push_back(unsigned int index) { indexesIntoParent_.push_back(index); }
27 
28  private:
31 
32  // The size of indexesIntoParent_ is the same as
33  // the size of the thinned collection and each
34  // element of indexesIntoParent corresponds to the
35  // element of the thinned collection at the same position.
36  // The values give the index of the corresponding element
37  // in the parent collection.
38  std::vector<unsigned int> indexesIntoParent_;
39  };
40 } // namespace edm
41 #endif
void setThinnedCollectionID(ProductID const &v)
std::vector< unsigned int > const & indexesIntoParent() const
std::vector< unsigned int > indexesIntoParent_
ProductID const & thinnedCollectionID() const
void push_back(unsigned int index)
void setParentCollectionID(ProductID const &v)
HLT enums.
ProductID const & parentCollectionID() const
bool hasParentIndex(unsigned int parentIndex, unsigned int &thinnedIndex) const