61{
62
63 ISvcLocator* svcLocator = Gaudi::svcLocator();
64 StatusCode sc=svcLocator->service("EventDataSvc", m_evtSvc);
65 if (sc.isFailure())
66 std::cout<<"Could not accesss EventDataSvc!"<<std::endl;
67
68 setFilterPassed(false);
69
70 SmartDataPtr<Event::EventHeader> eventHeader(m_evtSvc,"/Event/EventHeader");
71 if(!eventHeader)
72 std::cout<<"Could not retrieve EventHeader"<<std::endl;
73
74 int run=eventHeader->runNumber();
75 int event=eventHeader->eventNumber();
76 std::cout<<"run: "<<run<<" event: "<<event<<std::endl;
77
78 map<int,vector<int> >::iterator
iter = eventMap.find(run);
79 if(
iter!=eventMap.end()){
80 vector<int>::iterator it = find(
iter->second.begin(),
iter->second.end(), event);
81 if( it !=
iter->second.end() ) {
82 std::cout<<"find run: "<<run<<" event: "<<event<<std::endl;
83 setFilterPassed(true);
84 }
85 }
86
87 return StatusCode::SUCCESS;
88
89}