// Author: David Lawrence June 25, 2004 // // // MyProcessor.h // /// Example program for a Hall-D analyzer which uses DANA /// #ifndef _MyProcessor_ #define _MyProcessor_ #include #include #include #include #include "JANA/JEventProcessor.h" #include "DVector3.h" class DKinematicData; class DGeometry; class DSCHit; class MyProcessor:public jana::JEventProcessor { public: MyProcessor(std::vector& args, int max_events, string &output_file, bool batch_mode); jerror_t init(void); jerror_t brun(jana::JEventLoop *eventLoop, int runnumber); jerror_t evnt(jana::JEventLoop *eventLoop, int eventnumber); jerror_t erun(void); jerror_t fini(void); bool GetSCPlanesBarrel(std::vector& norms, std::vector& pts, std::vector& ang_edges_low); jerror_t MatchToSC(const DKinematicData* trk, const std::vector& sc_hits, const DSCHit*& assoc_hit) ; static std::string NtupleHeader; private: std::vector _args; int _max_events; std::string _output_file; bool _batch_mode; std::ofstream* _ofs; int _runno; std::map _geomap; // Geometry stuff DGeometry* _dgeo; std::vector _sc_phi_low_edges; std::vector _sc_barrel_norms; std::vector _sc_barrel_pts; std::vector _sc_nose_norms; std::vector _sc_nose_pts; }; #endif