ArchiveGetCommand.cpp

00001 #include "ArchiveGetCommand.h"
00002 #include "boost/timer.hpp"
00003 #include "Archiver.h"
00004 #include "Sct/Archive/IOManagerArchive.h"
00005 #include "Sct/File/IOManagerFile.h"
00006 
00007 namespace SctArchiving{
00008   ArchiveGetCommand::ArchiveGetCommand(boost::shared_ptr<Sct::Archive::IONameArchiveFile> name)
00009     : GetCommand(name)
00010   {}
00011 
00012   ArchiveGetCommand::ArchiveGetCommand() {}
00013   
00014   ArchiveGetCommand::~ArchiveGetCommand(){}
00015 
00016   void ArchiveGetCommand::execute(){
00017     boost::timer t;
00018     m_ob=Archiver::instance().getIOManagerArchive().read(m_name->getIOName());
00019     Archiver::instance().addFileTime(t.elapsed());
00020     Archiver::instance().incrimentNRetrieved();
00021   }
00022 
00023   boost::shared_ptr<ArchivingCommand> ArchiveGetCommand::create() const{
00024     return shared_ptr<ArchivingCommand>(new ArchiveGetCommand());
00025   }
00026 }

Generated on Mon Feb 6 14:01:16 2006 for SCT DAQ/DCS Software - C++ by  doxygen 1.4.6