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 1285 of file PFBlockAlgo.cc.

References gather_cfg::blocks, PFBlockAlgo::blocks(), PFBlockAlgo::elements_, cuy::ib, and dbtoconf::out.

1285  {
1286  if(! out) return out;
1287 
1288  out<<"====== Particle Flow Block Algorithm ======= ";
1289  out<<endl;
1290  out<<"number of unassociated elements : "<<a.elements_.size()<<endl;
1291  out<<endl;
1292 
1293  for(PFBlockAlgo::IEC ie = a.elements_.begin();
1294  ie != a.elements_.end(); ++ie) {
1295  out<<"\t"<<**ie <<endl;
1296  }
1297 
1298 
1299  // const PFBlockCollection& blocks = a.blocks();
1300 
1301  const std::auto_ptr< reco::PFBlockCollection >& blocks
1302  = a.blocks();
1303 
1304  if(!blocks.get() ) {
1305  out<<"blocks already transfered"<<endl;
1306  }
1307  else {
1308  out<<"number of blocks : "<<blocks->size()<<endl;
1309  out<<endl;
1310 
1311  for(PFBlockAlgo::IBC ib=blocks->begin();
1312  ib != blocks->end(); ++ib) {
1313  out<<(*ib)<<endl;
1314  }
1315  }
1316 
1317  return out;
1318 }
const std::auto_ptr< reco::PFBlockCollection > & blocks() const
Definition: PFBlockAlgo.h:194
int ib
Definition: cuy.py:660
std::list< reco::PFBlockElement * >::const_iterator IEC
Definition: PFBlockAlgo.h:202
std::list< reco::PFBlockElement * > elements_
actually, particles will be created by a separate producer
Definition: PFBlockAlgo.h:317
tuple out
Definition: dbtoconf.py:99
reco::PFBlockCollection::const_iterator IBC
Definition: PFBlockAlgo.h:203
list blocks
Definition: gather_cfg.py:90