CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions
PFBlockAlgo.cc File Reference
#include "RecoParticleFlow/PFProducer/interface/PFBlockAlgo.h"
#include "RecoParticleFlow/PFProducer/interface/Utils.h"
#include "RecoParticleFlow/PFClusterTools/interface/LinkByRecHit.h"
#include "DataFormats/ParticleFlowReco/interface/PFBlock.h"
#include "DataFormats/TrackReco/interface/Track.h"
#include "DataFormats/ParticleFlowReco/interface/PFDisplacedVertex.h"
#include "DataFormats/ParticleFlowReco/interface/PFRecHit.h"
#include <stdexcept>
#include "TMath.h"

Go to the source code of this file.

Functions

std::ostream & operator<< (std::ostream &out, const PFBlockAlgo &a)
 

Function Documentation

std::ostream& operator<< ( std::ostream &  out,
const PFBlockAlgo a 
)

Definition at line 1012 of file PFBlockAlgo.cc.

References PFBlockAlgo::blocks(), runregparse::blocks, PFBlockAlgo::elements_, and dbtoconf::out.

1012  {
1013  if(! out) return out;
1014 
1015  out<<"====== Particle Flow Block Algorithm ======= ";
1016  out<<endl;
1017  out<<"number of unassociated elements : "<<a.elements_.size()<<endl;
1018  out<<endl;
1019 
1020  for(PFBlockAlgo::IEC ie = a.elements_.begin();
1021  ie != a.elements_.end(); ie++) {
1022  out<<"\t"<<**ie <<endl;
1023  }
1024 
1025 
1026  // const PFBlockCollection& blocks = a.blocks();
1027 
1028  const std::auto_ptr< reco::PFBlockCollection >& blocks
1029  = a.blocks();
1030 
1031  if(!blocks.get() ) {
1032  out<<"blocks already transfered"<<endl;
1033  }
1034  else {
1035  out<<"number of blocks : "<<blocks->size()<<endl;
1036  out<<endl;
1037 
1038  for(PFBlockAlgo::IBC ib=blocks->begin();
1039  ib != blocks->end(); ib++) {
1040  out<<(*ib)<<endl;
1041  }
1042  }
1043 
1044  return out;
1045 }
const std::auto_ptr< reco::PFBlockCollection > & blocks() const
Definition: PFBlockAlgo.h:168
std::list< reco::PFBlockElement * >::const_iterator IEC
Definition: PFBlockAlgo.h:176
std::list< reco::PFBlockElement * > elements_
actually, particles will be created by a separate producer
Definition: PFBlockAlgo.h:274
tuple out
Definition: dbtoconf.py:99
reco::PFBlockCollection::const_iterator IBC
Definition: PFBlockAlgo.h:177