CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
GenericJet.cc
Go to the documentation of this file.
1 // GenericJet.cc
2 // Fedor Ratnikov, UMd
3 
4 #include <sstream>
5 
6 //Own header file
8 
9 using namespace reco;
10 
12  const Point& fVertex,
13  const std::vector<CandidateBaseRef>& fConstituents)
14  : CompositeRefBaseCandidate (0, fP4, fVertex)
15 {
16  for (unsigned i = 0; i < fConstituents.size (); i++) addDaughter (fConstituents [i]);
17 }
18 
20  return numberOfDaughters();
21 }
22 
24  std::ostringstream out;
25  out << "GenericJet p/px/py/pz/pt: " << p() << '/' << px () << '/' << py() << '/' << pz() << '/' << pt() << std::endl
26  << " eta/phi: " << eta () << '/' << phi () << std::endl
27  << " # of constituents: " << nConstituents () << std::endl;
28  out << " No Constituents details available for this version" << std::endl;
29  return out.str ();
30 }
virtual size_t numberOfDaughters() const
number of daughters
int i
Definition: DBlmapReader.cc:9
virtual double p() const
magnitude of momentum vector
GenericJet()
Default constructor.
Definition: GenericJet.h:22
virtual double eta() const
momentum pseudorapidity
virtual double pt() const
transverse momentum
virtual std::string print() const
Print object.
Definition: GenericJet.cc:23
virtual int nConstituents() const
of constituents
Definition: GenericJet.cc:19
tuple out
Definition: dbtoconf.py:99
virtual double px() const
x coordinate of momentum vector
virtual double pz() const
z coordinate of momentum vector
math::XYZTLorentzVector LorentzVector
Lorentz vector.
Definition: Candidate.h:37
math::XYZPoint Point
point in the space
Definition: Candidate.h:41
void addDaughter(const CandidateBaseRef &)
add a daughter via a reference
virtual double phi() const
momentum azimuthal angle
virtual double py() const
y coordinate of momentum vector