00001 // -*- C++ -*- 00002 #ifndef Fireworks_Core_FWNavigatorBase_h 00003 #define Fireworks_Core_FWNavigatorBase_h 00004 // 00005 // Package: newVersion 00006 // Class : CmsShowNavigator 00007 // $Id: FWNavigatorBase.h,v 1.4 2010/09/02 19:54:03 matevz Exp $ 00008 // 00009 00010 // system include files 00011 #include <string> 00012 #include <sigc++/sigc++.h> 00013 #include <Rtypes.h> 00014 00015 // user include files 00016 #include "Fireworks/Core/interface/FWConfigurable.h" 00017 00018 #include "DataFormats/Provenance/interface/EventID.h" 00019 00020 // forward declarations 00021 class CmsShowMainBase; 00022 00023 namespace edm { 00024 class EventBase; 00025 class EventID; 00026 } 00027 00028 class FWNavigatorBase : public FWConfigurable 00029 { 00030 public: 00031 enum EFilterState { kOff, kOn, kWithdrawn }; 00032 enum EFilterMode { kOr = 1, kAnd = 2 }; 00033 00034 public: 00035 FWNavigatorBase(const CmsShowMainBase &); 00036 virtual ~FWNavigatorBase(); 00037 00038 //configuration management interface 00039 virtual void addTo(FWConfiguration&) const = 0; 00040 virtual void setFrom(const FWConfiguration&) = 0; 00041 00042 virtual void nextEvent() = 0; 00043 virtual void previousEvent() = 0; 00044 virtual bool nextSelectedEvent() = 0; 00045 virtual bool previousSelectedEvent() = 0; 00046 virtual void firstEvent() = 0; 00047 virtual void lastEvent() = 0; 00048 // FIXME -- should be Long64_t. 00049 virtual void goToRunEvent(edm::RunNumber_t, edm::LuminosityBlockNumber_t, edm::EventNumber_t) = 0; 00050 00051 virtual bool isLastEvent() = 0; 00052 virtual bool isFirstEvent() = 0; 00053 00054 virtual const edm::EventBase* getCurrentEvent() const = 0; 00055 virtual int getNSelectedEvents() = 0; 00056 virtual int getNTotalEvents() = 0; 00057 00058 sigc::signal<void> newEvent_; 00059 private: 00060 FWNavigatorBase(const FWNavigatorBase&); // stop default 00061 const FWNavigatorBase& operator=(const FWNavigatorBase&); // stop default 00062 // ---------- member data -------------------------------- 00063 // entry is an event index nubmer which runs from 0 to 00064 // #events or #selected_events depending on if we filter 00065 // events or not 00066 const CmsShowMainBase &m_main; 00067 }; 00068 00069 #endif