CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_3/src/EventFilter/StorageManager/interface/EventStreamSelector.h

Go to the documentation of this file.
00001 // $Id: EventStreamSelector.h,v 1.8 2011/03/07 15:31:31 mommsen Exp $
00003 
00004 #ifndef EventFilter_StorageManager_EventStreamSelector_h
00005 #define EventFilter_StorageManager_EventStreamSelector_h
00006 
00007 #include <boost/shared_ptr.hpp>
00008 
00009 #include "EventFilter/StorageManager/interface/EventStreamConfigurationInfo.h"
00010 #include "EventFilter/StorageManager/interface/I2OChain.h"
00011 #include "EventFilter/StorageManager/interface/TriggerSelector.h"
00012 #include "IOPool/Streamer/interface/InitMessage.h"
00013 
00014 namespace stor {
00015 
00025   class EventStreamSelector
00026   {
00027 
00028   public:
00029 
00030     // Constructor:
00031     EventStreamSelector( const EventStreamConfigurationInfo& );
00032 
00033     // Destructor:
00034     ~EventStreamSelector() {}
00035 
00036     // Initialize:
00037     void initialize( const InitMsgView& );
00038 
00039     // Accept event:
00040     bool acceptEvent( const I2OChain& );
00041 
00042     // Accessors:
00043     unsigned int outputModuleId() const { return outputModuleId_; }
00044     const EventStreamConfigurationInfo& configInfo() const { return configInfo_; }
00045     bool isInitialized() const { return initialized_; }
00046 
00047     // Comparison:
00048     bool operator<(const EventStreamSelector& other) const
00049     { return ( configInfo_ < other.configInfo() ); }
00050 
00051   private:
00052 
00053     bool initialized_;
00054     unsigned int outputModuleId_;
00055     const EventStreamConfigurationInfo configInfo_;
00056 
00057     TriggerSelectorPtr eventSelector_;
00058 
00059   };
00060 
00061 } // namespace stor
00062 
00063 #endif // EventFilter_StorageManager_EventStreamSelector_h
00064 
00065