00001 #ifndef FILEREADOUTFORMAT_RAWFORMATBUILDER_H 00002 #define FILEREADOUTFORMAT_RAWFORMATBUILDER_H 00003 00004 /* 00005 * DaqFormatFromBytes.h 00006 * FileReadoutFormat 00007 * 00008 * Created by Simon Patton on 7/18/10. 00009 * Copyright 2010 DayaBay Collaboration. All rights reserved. 00010 * 00011 */ 00012 namespace DybDaq { 00013 class ByteBuffer; 00014 class FileTraits; 00015 } 00016 00017 namespace DybDaq { 00018 00019 class DaqFormatFromBytes { 00020 00021 public: 00022 00026 DaqFormatFromBytes(); 00027 00031 virtual ~DaqFormatFromBytes(); 00032 00036 unsigned int additionalCapacity(); 00037 00041 const FileBuffer* createFileBuffer(const ByteBuffer* buffer); 00042 00043 private: 00044 00048 DaqFormatFromBytes(DaqFormatFromBytes& rhs); 00049 00053 DaqFormatFromBytes& operator=(DaqFormatFromBytes& rhs); 00054 00058 const FileBuffer* processMarker(const ByteBuffer* buffer, 00059 unsigned int marker); 00060 00061 00065 const FileTraits* m_traits; 00066 00070 unsigned int m_additionalCapacity; 00071 }; 00072 00073 } 00074 00075 #endif // FILEREADOUTFORMAT_RAWFORMATBUILDER_H