CMS 3D CMS Logo

Typedefs | Functions
MtdSimClusterFwd.h File Reference
#include "DataFormats/Common/interface/Ref.h"
#include "DataFormats/Common/interface/RefProd.h"
#include "DataFormats/Common/interface/RefVector.h"
#include <vector>

Go to the source code of this file.

Typedefs

typedef std::vector< MtdSimClusterMtdSimClusterCollection
 
typedef edm::RefVector< MtdSimClusterCollectionMtdSimClusterContainer
 
typedef edm::Ref< MtdSimClusterCollectionMtdSimClusterRef
 
typedef edm::RefProd< MtdSimClusterCollectionMtdSimClusterRefProd
 
typedef edm::RefVector< MtdSimClusterCollectionMtdSimClusterRefVector
 

Functions

std::ostream & operator<< (std::ostream &s, MtdSimCluster const &tp)
 

Typedef Documentation

◆ MtdSimClusterCollection

typedef std::vector<MtdSimCluster> MtdSimClusterCollection

Definition at line 8 of file MtdSimClusterFwd.h.

◆ MtdSimClusterContainer

Definition at line 13 of file MtdSimClusterFwd.h.

◆ MtdSimClusterRef

Definition at line 10 of file MtdSimClusterFwd.h.

◆ MtdSimClusterRefProd

Definition at line 12 of file MtdSimClusterFwd.h.

◆ MtdSimClusterRefVector

Definition at line 11 of file MtdSimClusterFwd.h.

Function Documentation

◆ operator<<()

std::ostream& operator<< ( std::ostream &  s,
MtdSimCluster const &  tp 
)

Definition at line 27 of file MtdSimCluster.cc.

References alignCSCRings::s, and cmsswSequenceInfo::tp.

27  {
28  s << "CP momentum, q, ID, & Event #: " << tp.p4() << " " << tp.charge() << " " << tp.pdgId() << " "
29  << tp.eventId().bunchCrossing() << "." << tp.eventId().event() << std::endl;
30 
31  for (MtdSimCluster::genp_iterator hepT = tp.genParticle_begin(); hepT != tp.genParticle_end(); ++hepT) {
32  s << " HepMC Track Momentum " << (*hepT)->momentum().rho() << std::endl;
33  }
34 
35  for (MtdSimCluster::g4t_iterator g4T = tp.g4Track_begin(); g4T != tp.g4Track_end(); ++g4T) {
36  s << " Geant Track Momentum " << g4T->momentum() << std::endl;
37  s << " Geant Track ID & type " << g4T->trackId() << " " << g4T->type() << std::endl;
38  if (g4T->type() != tp.pdgId()) {
39  s << " Mismatch b/t MtdSimCluster and Geant types" << std::endl;
40  }
41  }
42  s << " # of cells = " << tp.hits_.size()
43  << ", effective cells = " << std::accumulate(tp.fractions_.begin(), tp.fractions_.end(), 0.f) << std::endl;
44  return s;
45 }
std::vector< SimTrack >::const_iterator g4t_iterator
Definition: SimCluster.h:45