00001 /****************************************************************************** 00002 ** Copyright (c) 1992-2010 VT MAK 00003 ** All rights reserved. 00004 ******************************************************************************/ 00005 00009 00010 #ifndef loggerOutputFile_H_ 00011 #define loggerOutputFile_H_ 00012 00013 #include "loggerFile.h" 00014 #include "filePosition.h" 00015 00016 class DtString; 00017 00018 namespace MAKLogger 00019 { 00022 class DT_DLL_LGRCORE DtLoggerOutputFile : public DtLoggerFile 00023 { 00024 00025 public: 00028 DtLoggerOutputFile(const DtString& filename, int version); 00029 00030 private: 00032 DtLoggerOutputFile(const DtLoggerOutputFile&); 00034 DtLoggerOutputFile& operator=(const DtLoggerOutputFile&); 00035 public: 00036 00038 virtual ~DtLoggerOutputFile(); 00039 00041 virtual int fileDescriptor(); 00042 00045 virtual DtFilePosition startOfData(); 00046 00048 virtual DtFilePosition fileSize(); 00049 00050 protected: 00051 00053 void openFileForOutput(); 00054 00056 void writeFileVersion(int version); 00057 00059 virtual void setFileDescriptor(int fd); 00060 00061 protected: 00062 int myFileDescriptor; 00063 }; 00064 } 00065 00066 #endif