00001 #ifndef SCTDATA_IO_RAWSCANRESULTSTREAMER_H
00002 #define SCTDATA_IO_RAWSCANRESULTSTREAMER_H
00003
00004 #include "../RawScanResultIOHelper.h"
00005 #include "ScanResultStreamer.h"
00006
00007 class SctData::RawScanResult;
00008 class TH1;
00009
00010 using namespace Sct;
00011
00012 namespace SctData {
00013 namespace IO {
00014
00015
00019 class RawScanResultStreamer : public ScanResultStreamer {
00020 public:
00021
00022 virtual void write(OStream& out, const Streamable& ob, const IOManager& manager) const throw(LogicError, IoError);
00023 virtual shared_ptr<Streamable> read(IStream& in, const IOManager& manager) const throw(LogicError, IoError);
00024 virtual void read(IStream& in, Streamable& ob, const IOManager& manager) const throw(LogicError, IoError);
00025
00026 private:
00030 void readData(IStream& in, RawScanResult& raw) const throw(LogicError, IoError);
00031
00035 void readSliceData(unsigned int size, unsigned short width, IStream& in, RawScanResult& raw) const throw(LogicError, IoError);
00036
00040 void readRootData(unsigned int size, unsigned short width, IStream& in, RawScanResult& raw) const throw(LogicError, IoError);
00041
00042
00043 mutable RawScanResultIOHelper helper;
00044 RawScanResultStreamer() throw();
00045 static bool inMap;
00046 };
00047
00048 }
00049 }
00050 #endif //#ifndef SCTDATA_IO_RAWSCANRESULTSTREAMER_H