CMS 3D CMS Logo

Public Types | Public Member Functions | Protected Member Functions | Protected Attributes

CompositeTSG Class Reference

#include <CompositeTSG.h>

Inheritance diagram for CompositeTSG:
TrackerSeedGenerator CombinedTSG SeparatingTSG DualByEtaTSG DualByL2TSG

List of all members.

Public Types

typedef std::vector
< TrajectorySeed
BTSeedCollection
typedef std::pair< const
Trajectory *, reco::TrackRef
TrackCand

Public Member Functions

 CompositeTSG (const edm::ParameterSet &pset)
void init (const MuonServiceProxy *service)
 initialized the TSGs
void setEvent (const edm::Event &event)
 set the event to the TSGs
virtual void trackerSeeds (const TrackCand &, const TrackingRegion &, const TrackerTopology *, BTSeedCollection &)=0
 provides the seeds from the TSGs: must be overloaded
virtual ~CompositeTSG ()

Protected Member Functions

unsigned int nTSGs ()

Protected Attributes

std::string theCategory
std::vector< std::string > theNames
const MuonServiceProxytheProxyService
std::vector
< TrackerSeedGenerator * > 
theTSGs

Detailed Description

Description: TrackerSeedGenerator generic class to allow more than one TSG to be used. used as a SeparatingTSG of CombinedTSG

Author:
Jean-Roch Vlimant, Adam Everett

Definition at line 20 of file CompositeTSG.h.


Member Typedef Documentation

Reimplemented from TrackerSeedGenerator.

Definition at line 23 of file CompositeTSG.h.

Reimplemented from TrackerSeedGenerator.

Definition at line 24 of file CompositeTSG.h.


Constructor & Destructor Documentation

CompositeTSG::CompositeTSG ( const edm::ParameterSet pset)

Definition at line 7 of file CompositeTSG.cc.

References SurfaceDeformationFactory::create(), edm::ParameterSet::empty(), reco::get(), edm::ParameterSet::getParameter(), AlCaHLTBitMon_QueryRunRegistry::string, theCategory, theNames, and theTSGs.

                                                     {
  theCategory = "CompositeTSG";

  //configure the individual components of the TSG
  std::vector<std::string> PSetNames =  par.getParameter<std::vector<std::string> >("PSetNames");

  for (std::vector<std::string>::iterator nIt = PSetNames.begin();nIt!=PSetNames.end();nIt++){
    edm::ParameterSet TSGpset = par.getParameter<edm::ParameterSet>(*nIt);
    if (TSGpset.empty()) {
      theNames.push_back((*nIt)+":"+"NULL");
      theTSGs.push_back((TrackerSeedGenerator*)(0));
    }else {
      std::string SeedGenName = TSGpset.getParameter<std::string>("ComponentName");
      theNames.push_back((*nIt)+":"+SeedGenName);
      theTSGs.push_back(TrackerSeedGeneratorFactory::get()->create(SeedGenName,TSGpset));
    }
  }
  
}
CompositeTSG::~CompositeTSG ( ) [virtual]

Definition at line 27 of file CompositeTSG.cc.

                           {
  //delete the components ?
}

Member Function Documentation

void CompositeTSG::init ( const MuonServiceProxy service) [virtual]

initialized the TSGs

Reimplemented from TrackerSeedGenerator.

Definition at line 32 of file CompositeTSG.cc.

References theProxyService, and theTSGs.

                                                      {
  theProxyService = service;
  for (unsigned int iTSG=0; iTSG!=theTSGs.size();iTSG++){
    if(theTSGs[iTSG]) theTSGs[iTSG]->init(service);
  }
}
unsigned int CompositeTSG::nTSGs ( ) [inline, protected]

Definition at line 39 of file CompositeTSG.h.

References theTSGs.

Referenced by DualByEtaTSG::DualByEtaTSG(), and DualByL2TSG::DualByL2TSG().

{ return theTSGs.size();}
void CompositeTSG::setEvent ( const edm::Event event) [virtual]

set the event to the TSGs

Reimplemented from TrackerSeedGenerator.

Definition at line 39 of file CompositeTSG.cc.

References event(), TrackerSeedGenerator::theEvent, and theTSGs.

                                                {
  theEvent = &event;
  for (unsigned int iTSG=0; iTSG!=theTSGs.size();iTSG++){
    if(theTSGs[iTSG]) theTSGs[iTSG]->setEvent(event);
  }
}
virtual void CompositeTSG::trackerSeeds ( const TrackCand ,
const TrackingRegion ,
const TrackerTopology ,
BTSeedCollection  
) [pure virtual]

provides the seeds from the TSGs: must be overloaded

Reimplemented from TrackerSeedGenerator.

Implemented in CombinedTSG, and SeparatingTSG.


Member Data Documentation

std::string CompositeTSG::theCategory [protected]

Reimplemented in CombinedTSG, DualByEtaTSG, DualByL2TSG, and SeparatingTSG.

Definition at line 42 of file CompositeTSG.h.

Referenced by CompositeTSG().

std::vector<std::string> CompositeTSG::theNames [protected]

Definition at line 41 of file CompositeTSG.h.

Referenced by CompositeTSG(), and SeparatingTSG::trackerSeeds().

Reimplemented from TrackerSeedGenerator.

Definition at line 44 of file CompositeTSG.h.

Referenced by init().

std::vector<TrackerSeedGenerator*> CompositeTSG::theTSGs [protected]