#include "SimDataFormats/TrackingAnalysis/interface/TrackingVertexContainer.h"
#include "SimDataFormats/TrackingAnalysis/interface/TrackingVertex.h"
Go to the source code of this file.
Typedefs | |
typedef edm::Ref < edm::HepMCProduct, HepMC::GenVertex > | GenVertexRef |
typedef edm::RefVector < edm::HepMCProduct, HepMC::GenVertex > | GenVertexRefVector |
Functions | |
std::ostream & | operator<< (std::ostream &s, const TrackingVertex &v) |
typedef edm::Ref<edm::HepMCProduct, HepMC::GenVertex > GenVertexRef |
Definition at line 5 of file TrackingVertex.cc.
typedef edm::RefVector<edm::HepMCProduct, HepMC::GenVertex > GenVertexRefVector |
Definition at line 4 of file TrackingVertex.cc.
std::ostream& operator<< | ( | std::ostream & | s, |
const TrackingVertex & | v | ||
) |
Definition at line 110 of file TrackingVertex.cc.
References EncodedEventId::bunchCrossing(), TrackingVertex::daughterTracks(), TrackingVertex::daughterTracks_begin(), TrackingVertex::daughterTracks_end(), EncodedEventId::event(), TrackingVertex::eventId(), TrackingVertex::g4Vertices_begin(), TrackingVertex::g4Vertices_end(), TrackingVertex::genVertices_begin(), TrackingVertex::genVertices_end(), TrackingVertex::position(), position, alignCSCRings::s, edm::RefVector< C, T, F >::size(), TrackingVertex::sourceTracks_begin(), and TrackingVertex::sourceTracks_end().
{ using std::endl; typedef GenVertexRefVector::iterator genv_iterator; typedef std::vector<SimVertex>::const_iterator g4v_iterator; typedef TrackingParticleRefVector::iterator tp_iterator; typedef std::vector<SimTrack>::const_iterator g4t_iterator; s << "Vertex Position & Event #" << v.position() << " " << v.eventId().bunchCrossing() << "." << v.eventId().event() << endl; s << " Associated with " << v.daughterTracks().size() << " tracks" << endl; for (genv_iterator genV = v.genVertices_begin(); genV != v.genVertices_end(); ++genV) { s << " HepMC vertex position " << (*(*genV)).position().x() << ","<< (*(*genV)).position().y() << (*(*genV)).position().z() << endl; } for (g4v_iterator g4V = v.g4Vertices_begin(); g4V != v.g4Vertices_end(); ++g4V) { s << " Geant vertex position " << (*g4V).position() << endl; // Probably empty all the time, currently } // Loop over daughter track(s) for (tp_iterator iTP = v.daughterTracks_begin(); iTP != v.daughterTracks_end(); ++iTP) { s << " Daughter starts: " << (*(*iTP)).vertex(); for (g4t_iterator g4T = (*(*iTP)).g4Track_begin(); g4T != (*(*iTP)).g4Track_end(); ++g4T) { s << " p " << g4T->momentum(); } s << endl; } // Loop over source track(s) (can be multiple since vertices are collapsed) for (tp_iterator iTP = v.sourceTracks_begin(); iTP != v.sourceTracks_end(); ++iTP) { s << " Source starts: " << (*(*iTP)).vertex(); for (g4t_iterator g4T = (*iTP)->g4Track_begin(); g4T != (*iTP)->g4Track_end(); ++g4T) { s << ", p " << g4T ->momentum(); } s << endl; } return s; }