Skip to content

Commit

Permalink
Merge pull request #12461 from ianna/geometry-analyzers
Browse files Browse the repository at this point in the history
Thread-safe ED Analyzers
  • Loading branch information
davidlange6 committed Nov 19, 2015
2 parents 513daeb + ee0db90 commit d14a8e0
Show file tree
Hide file tree
Showing 10 changed files with 195 additions and 289 deletions.
48 changes: 23 additions & 25 deletions Geometry/CSCGeometry/test/stubs/CSCGACwithB.cc
Expand Up @@ -2,41 +2,39 @@
// at centre of each CSC (Nikolai Terentiev needed the values for CSC gain studies.)
// Tim Cox 11.03.2011 - drop ME1/A

#include <memory>

#include <FWCore/Framework/interface/EDAnalyzer.h>
#include <FWCore/Framework/interface/EventSetup.h>
#include <FWCore/Framework/interface/ESHandle.h>
#include <FWCore/Framework/interface/MakerMacros.h>

#include <Geometry/Records/interface/MuonGeometryRecord.h>
#include <MagneticField/Records/interface/IdealMagneticFieldRecord.h>
#include <Geometry/CSCGeometry/interface/CSCGeometry.h>
#include <Geometry/CSCGeometry/interface/CSCLayer.h>
#include <DataFormats/GeometryVector/interface/GlobalPoint.h>
#include <MagneticField/Engine/interface/MagneticField.h>
#include "FWCore/Framework/interface/EDAnalyzer.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#include "Geometry/Records/interface/MuonGeometryRecord.h"
#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h"
#include "Geometry/CSCGeometry/interface/CSCGeometry.h"
#include "Geometry/CSCGeometry/interface/CSCLayer.h"
#include "DataFormats/GeometryVector/interface/GlobalPoint.h"
#include "MagneticField/Engine/interface/MagneticField.h"

#include <string>
#include <cmath>
#include <iomanip> // for setw() etc.
#include <vector>

class CSCGACwithB : public edm::EDAnalyzer {
class CSCGACwithB : public edm::one::EDAnalyzer<> {

public:
public:

explicit CSCGACwithB( const edm::ParameterSet& );
~CSCGACwithB();
explicit CSCGACwithB( const edm::ParameterSet& );
~CSCGACwithB();

virtual void analyze( const edm::Event&, const edm::EventSetup& );

const std::string& myName() { return myName_;}
void beginJob() override {}
void analyze(edm::Event const&, edm::EventSetup const&) override;
void endJob() override {}

const std::string& myName() { return myName_;}

private:
private:

const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
};

CSCGACwithB::CSCGACwithB( const edm::ParameterSet& iConfig )
Expand Down
46 changes: 21 additions & 25 deletions Geometry/CSCGeometry/test/stubs/CSCGeometryAnalyzer.cc
@@ -1,39 +1,35 @@
#include <memory>

#include <FWCore/Framework/interface/EDAnalyzer.h>
#include <FWCore/Framework/interface/EventSetup.h>
#include <FWCore/Framework/interface/ESHandle.h>
#include <FWCore/Framework/interface/MakerMacros.h>

//#include <Geometry/CommonDetUnit/interface/TrackingGeometry.h>
#include <Geometry/Records/interface/MuonGeometryRecord.h>

#include <Geometry/CSCGeometry/interface/CSCGeometry.h>
#include <Geometry/CSCGeometry/interface/CSCLayer.h>
#include <DataFormats/GeometryVector/interface/Pi.h>
#include <DataFormats/GeometryVector/interface/GlobalPoint.h>
#include "FWCore/Framework/interface/one/EDAnalyzer.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#include "Geometry/Records/interface/MuonGeometryRecord.h"
#include "Geometry/CSCGeometry/interface/CSCGeometry.h"
#include "Geometry/CSCGeometry/interface/CSCLayer.h"
#include "DataFormats/GeometryVector/interface/Pi.h"
#include "DataFormats/GeometryVector/interface/GlobalPoint.h"

#include <string>
#include <cmath>
#include <iomanip> // for setw() etc.
#include <vector>

class CSCGeometryAnalyzer : public edm::EDAnalyzer {
class CSCGeometryAnalyzer : public edm::one::EDAnalyzer<> {

public:
public:

explicit CSCGeometryAnalyzer( const edm::ParameterSet& );
~CSCGeometryAnalyzer();
explicit CSCGeometryAnalyzer( const edm::ParameterSet& );
~CSCGeometryAnalyzer();

virtual void analyze( const edm::Event&, const edm::EventSetup& );
void beginJob() override {}
void analyze(edm::Event const&, edm::EventSetup const&) override;
void endJob() override {}

const std::string& myName() { return myName_;}
const std::string& myName() { return myName_;}

private:
private:

const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
};

CSCGeometryAnalyzer::CSCGeometryAnalyzer( const edm::ParameterSet& iConfig )
Expand Down
46 changes: 22 additions & 24 deletions Geometry/CSCGeometry/test/stubs/CSCGeometryAsChambers.cc
@@ -1,36 +1,34 @@
#include <memory>

#include <FWCore/Framework/interface/EDAnalyzer.h>
#include <FWCore/Framework/interface/EventSetup.h>
#include <FWCore/Framework/interface/ESHandle.h>
#include <FWCore/Framework/interface/MakerMacros.h>

#include <Geometry/Records/interface/MuonGeometryRecord.h>
#include <Geometry/CSCGeometry/interface/CSCGeometry.h>
#include <Geometry/CSCGeometry/interface/CSCLayer.h>
#include <DataFormats/GeometryVector/interface/GlobalPoint.h>
#include "FWCore/Framework/interface/one/EDAnalyzer.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#include "Geometry/Records/interface/MuonGeometryRecord.h"
#include "Geometry/CSCGeometry/interface/CSCGeometry.h"
#include "Geometry/CSCGeometry/interface/CSCLayer.h"
#include "DataFormats/GeometryVector/interface/GlobalPoint.h"

#include <string>
#include <cmath>
#include <iomanip> // for setw() etc.
#include <vector>

class CSCGeometryAsChambers : public edm::EDAnalyzer {

public:

explicit CSCGeometryAsChambers( const edm::ParameterSet& );
~CSCGeometryAsChambers();
class CSCGeometryAsChambers : public edm::one::EDAnalyzer<> {

virtual void analyze( const edm::Event&, const edm::EventSetup& );
public:

const std::string& myName() { return myName_;}
explicit CSCGeometryAsChambers( const edm::ParameterSet& );
~CSCGeometryAsChambers();

private:
void beginJob() override {}
void analyze(edm::Event const&, edm::EventSetup const&) override;
void endJob() override {}

const std::string& myName() { return myName_;}

private:

const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
};

CSCGeometryAsChambers::CSCGeometryAsChambers( const edm::ParameterSet& iConfig )
Expand Down
48 changes: 24 additions & 24 deletions Geometry/CSCGeometry/test/stubs/CSCGeometryAsLayers.cc
@@ -1,35 +1,35 @@
#include <FWCore/Framework/interface/EDAnalyzer.h>
#include <FWCore/Framework/interface/EventSetup.h>
#include <FWCore/Framework/interface/ESHandle.h>
#include <FWCore/Framework/interface/MakerMacros.h>

#include <DataFormats/GeometryVector/interface/Pi.h>
#include <Geometry/Records/interface/MuonGeometryRecord.h>
#include <Geometry/CSCGeometry/interface/CSCGeometry.h>
#include <Geometry/CSCGeometry/interface/CSCLayer.h>
#include <DataFormats/GeometryVector/interface/GlobalPoint.h>
#include "FWCore/Framework/interface/one/EDAnalyzer.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#include "DataFormats/GeometryVector/interface/Pi.h"
#include "Geometry/Records/interface/MuonGeometryRecord.h"
#include "Geometry/CSCGeometry/interface/CSCGeometry.h"
#include "Geometry/CSCGeometry/interface/CSCLayer.h"
#include "DataFormats/GeometryVector/interface/GlobalPoint.h"

#include <string>
#include <cmath>
#include <iomanip> // for setw() etc.
#include <vector>

class CSCGeometryAsLayers : public edm::EDAnalyzer {

public:

explicit CSCGeometryAsLayers( const edm::ParameterSet& );
~CSCGeometryAsLayers();

virtual void analyze( const edm::Event&, const edm::EventSetup& );
class CSCGeometryAsLayers : public edm::one::EDAnalyzer<> {

public:

const std::string& myName() { return myName_;}
explicit CSCGeometryAsLayers( const edm::ParameterSet& );
~CSCGeometryAsLayers();

private:
void beginJob() override {}
void analyze(edm::Event const&, edm::EventSetup const&) override;
void endJob() override {}

const std::string& myName() { return myName_;}

private:

const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
};

CSCGeometryAsLayers::CSCGeometryAsLayers( const edm::ParameterSet& iConfig )
Expand Down
42 changes: 21 additions & 21 deletions Geometry/CSCGeometry/test/stubs/CSCGeometryOfStrips.cc
@@ -1,34 +1,34 @@
#include <FWCore/Framework/interface/EDAnalyzer.h>
#include <FWCore/Framework/interface/EventSetup.h>
#include <FWCore/Framework/interface/ESHandle.h>
#include <FWCore/Framework/interface/MakerMacros.h>

#include <Geometry/Records/interface/MuonGeometryRecord.h>
#include <Geometry/CSCGeometry/interface/CSCGeometry.h>
#include <Geometry/CSCGeometry/interface/CSCLayer.h>
#include <Geometry/CSCGeometry/interface/CSCLayerGeometry.h>
#include "FWCore/Framework/interface/one/EDAnalyzer.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#include "Geometry/Records/interface/MuonGeometryRecord.h"
#include "Geometry/CSCGeometry/interface/CSCGeometry.h"
#include "Geometry/CSCGeometry/interface/CSCLayer.h"
#include "Geometry/CSCGeometry/interface/CSCLayerGeometry.h"

#include <string>
#include <cmath>
#include <iomanip> // for setw() etc.
#include <vector>

class CSCGeometryOfStrips : public edm::EDAnalyzer {
class CSCGeometryOfStrips : public edm::one::EDAnalyzer<> {

public:
public:

explicit CSCGeometryOfStrips( const edm::ParameterSet& );
~CSCGeometryOfStrips();
explicit CSCGeometryOfStrips( const edm::ParameterSet& );
~CSCGeometryOfStrips();

virtual void analyze( const edm::Event&, const edm::EventSetup& );

const std::string& myName() { return myName_;}
void beginJob() override {}
void analyze(edm::Event const&, edm::EventSetup const&) override;
void endJob() override {}

const std::string& myName() { return myName_;}

private:
private:

const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
};

CSCGeometryOfStrips::CSCGeometryOfStrips( const edm::ParameterSet& iConfig )
Expand Down
44 changes: 22 additions & 22 deletions Geometry/CSCGeometry/test/stubs/CSCGeometryOfWires.cc
@@ -1,38 +1,38 @@
// LAST UPDATED 16.09.2009 ptc

#include <FWCore/Framework/interface/EDAnalyzer.h>
#include <FWCore/Framework/interface/EventSetup.h>
#include <FWCore/Framework/interface/ESHandle.h>
#include <FWCore/Framework/interface/MakerMacros.h>

#include <Geometry/Records/interface/MuonGeometryRecord.h>
#include <Geometry/CSCGeometry/interface/CSCGeometry.h>
#include <Geometry/CSCGeometry/interface/CSCLayer.h>
#include <Geometry/CSCGeometry/interface/CSCLayerGeometry.h>
#include <DataFormats/GeometryVector/interface/Pi.h>
#include <DataFormats/GeometryVector/interface/GlobalPoint.h>
#include "FWCore/Framework/interface/one/EDAnalyzer.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#include "Geometry/Records/interface/MuonGeometryRecord.h"
#include "Geometry/CSCGeometry/interface/CSCGeometry.h"
#include "Geometry/CSCGeometry/interface/CSCLayer.h"
#include "Geometry/CSCGeometry/interface/CSCLayerGeometry.h"
#include "DataFormats/GeometryVector/interface/Pi.h"
#include "DataFormats/GeometryVector/interface/GlobalPoint.h"

#include <string>
#include <cmath>
#include <iomanip> // for setw() etc.
#include <vector>

class CSCGeometryOfWires : public edm::EDAnalyzer {
class CSCGeometryOfWires : public edm::one::EDAnalyzer<> {

public:
public:

explicit CSCGeometryOfWires( const edm::ParameterSet& );
~CSCGeometryOfWires();
explicit CSCGeometryOfWires( const edm::ParameterSet& );
~CSCGeometryOfWires();

virtual void analyze( const edm::Event&, const edm::EventSetup& );
void beginJob() override {}
void analyze(edm::Event const&, edm::EventSetup const&) override;
void endJob() override {}

const std::string& myName() { return myName_;}
const std::string& myName() { return myName_;}

private:
private:

const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
const int dashedLineWidth_;
const std::string dashedLine_;
const std::string myName_;
};

CSCGeometryOfWires::CSCGeometryOfWires( const edm::ParameterSet& iConfig )
Expand Down

0 comments on commit d14a8e0

Please sign in to comment.