00001 #ifndef GZIPOUTPUTSTREAM_H
00002 #define GZIPOUTPUTSTREAM_H
00003
00004 #include "zipios++/zipios-config.h"
00005
00006 #include "zipios++/meta-iostreams.h"
00007
00008 #include <string>
00009
00010 #include "zipios++/gzipoutputstreambuf.h"
00011
00012 namespace zipios {
00013
00017 class GZIPOutputStream : public std::ostream {
00018 public:
00019
00023 explicit GZIPOutputStream( std::ostream &os ) ;
00024
00027 explicit GZIPOutputStream( const std::string &filename ) ;
00028
00029 void setFilename( const string &filename );
00030 void setComment( const string &comment );
00031
00033 void close() ;
00034
00036 void finish() ;
00037
00039 virtual ~GZIPOutputStream() ;
00040
00041 private:
00042 std::ofstream *ofs ;
00043 GZIPOutputStreambuf *ozf ;
00044 };
00045
00046 }
00047
00048 #endif
00049
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071