/** \file Declaration of class EventFileChain \author Stefano Argiro \version $Id: EventFileChain.h 16675 2010-06-01 17:07:31Z paul $ \date 02 Feb 2004 */ #ifndef _io_EventFileChain_h_ #define _io_EventFileChain_h_ static const char CVSId_io_EventFileChain[] = "$Id: EventFileChain.h 16675 2010-06-01 17:07:31Z paul $"; #include #include #include #include namespace evt { class Event; } namespace io { class EventFile; /** \class EventFileChain EventFileChain.h "io/EventFileChain.h" \brief A collection of EventFile \author Stefano Argiro` \date 02 Feb 2004 \ingroup offline_io */ class EventFileChain { public: EventFileChain(const Type type); /// Create from a list of file names separated by a space /** This will trow an IOFailure exception if one of the filenams * does not exist */ EventFileChain(const std::string& filenames, const Type type); /// Create from a vector of strings EventFileChain(const std::vector& filenames, const Type type); ~EventFileChain(); /// read current event and advance cursor by 1 /** Will step to the next file if necessary*/ Status Read(evt::Event& event); const std::string& GetCurrentFilename() const; void SetParsingOptions(const bool interpretBacktick) { fInterpretBacktick = interpretBacktick; } void SetFileList(const std::vector& filenames); private: /// Copy construction is disallowed inline EventFileChain(const EventFileChain& theEventFileChain); /// Copy construction is disallowed inline EventFileChain& operator=(const EventFileChain& theEventFileChain); inline Status OpenCurrent(); void Parse(); static void InitXMLDictionary(); typedef std::vector FileContainer; FileContainer fFileList; FileContainer::iterator fFileIterator; EventFile* fOpenFile; Type fType; bool fInterpretBacktick; static std::map fgXMLDictionary; }; } namespace utl { template<> void Branch::GetData(io::EventFileChain&) const; } #endif // Configure (x)emacs for this file ... // Local Variables: // mode: c++ // compile-command: "make -C .. -k" // End: