#ifndef ACCESSCHUNKS_HPP_ #define ACCESSCHUNKS_HPP_ #include #include #include "framework/Package.hpp" #include "framework/interfaces/Flow.hpp" #include "framework/interfaces/StandAlone.hpp" #include "edm/TKey.hpp" namespace edm { class Event; } namespace emid { class EMparticleChunk; } namespace jetid { class JetChunk; } class HepRootFileManager; class TH1F; class TH2F; namespace d0tutorial { class AccessChunks : public fwk::Package, public fwk::Analyze, public fwk::JobSummary { public: AccessChunks(fwk::Context *ctx); virtual ~AccessChunks(); virtual fwk::Result analyzeEvent(const edm::Event& event); virtual fwk::Result jobSummary(); virtual std::string packageName() const { return package_name(); } static const std::string package_name() { return "AccessChunks"; } static const std::string version() { return "$Id"; } private: void access_em(const edm::Event& event); void access_jet(const edm::Event& event); void access_muon(const edm::Event& event); void access_met(const edm::Event& event); void access_tracks(const edm::Event& event); private: bool _debug; std::string _histofile_name; unsigned int _events_processed; edm::TKey _emKey; edm::TKey _jetKey; TH1F *_em_pT; TH1F *_mu_pT; TH1F *_jet_pT; TH1F *_met; HepRootFileManager *_mgr; }; } #endif // ACCESSCHUNKS_HPP_