CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CompositePtrCandidate.cc
Go to the documentation of this file.
1 // $Id: CompositePtrCandidate.cc,v 1.4 2010/12/06 20:04:17 wmtan Exp $
4 
5 using namespace reco;
6 
8 }
9 
11  return new CompositePtrCandidate( * this );
12 }
13 
15  return const_iterator( new const_iterator_imp_specific( dau.begin() ) );
16 }
17 
19  return const_iterator( new const_iterator_imp_specific( dau.end() ) );
20 }
21 
23  return iterator( new iterator_imp_specific );
24 }
25 
27  return iterator( new iterator_imp_specific );
28 }
29 
31  return ( i < numberOfDaughters() ) ? & * dau[ i ] : 0; // i >= 0, since i is unsigned
32 }
33 
35  return 0;
36 }
37 
39  return 0;
40 }
41 
43  return dau.size();
44 }
45 
47  return 0;
48 }
49 
51  return numberOfDaughters();
52 }
53 
55  return daughterPtr(i);
56 }
57 
58 bool CompositePtrCandidate::overlap( const Candidate & c2 ) const {
59  throw cms::Exception( "Error" ) << "can't check overlap internally for CompositePtrCanddate";
60 }
int i
Definition: DBlmapReader.cc:9
CompositePtrCandidate()
default constructor
size_t size_type
Definition: Candidate.h:31
CandidatePtr daughterPtr(size_type i) const
reference to daughter at given position
candidate::const_iterator const_iterator
Definition: Candidate.h:32
daughters dau
collection of references to daughters
virtual CompositePtrCandidate * clone() const
returns a clone of the candidate
virtual size_t numberOfDaughters() const
number of daughters
virtual CandidatePtr sourceCandidatePtr(size_type i) const
virtual size_type numberOfSourceCandidatePtrs() const
candidate::const_iterator_imp_specific< daughters > const_iterator_imp_specific
const iterator implementation
virtual const Candidate * mother(size_t i=0) const
return pointer to mother
virtual ~CompositePtrCandidate()
destructor
candidate::iterator iterator
Definition: Candidate.h:33
virtual const_iterator begin() const
first daughter const_iterator
virtual bool overlap(const Candidate &) const
check overlap with another candidate
virtual size_t numberOfMothers() const
number of mothers
virtual const_iterator end() const
last daughter const_iterator
virtual const Candidate * daughter(size_type) const
return daughter at a given position, i = 0, ... numberOfDaughters() - 1 (read only mode) ...