Main Page   Class Hierarchy   Compound List   File List   Compound Members  

zipoutputstream.h

Go to the documentation of this file.
00001 #ifndef ZIPOUTPUTSTREAM_H
00002 #define ZIPOUTPUTSTREAM_H
00003 
00004 #include "zipios++/zipios-config.h"
00005 
00006 #include "zipios++/meta-iostreams.h"
00007 
00008 #include <string>
00009 
00010 #include "zipios++/ziphead.h"
00011 #include "zipios++/zipoutputstreambuf.h"
00012 
00013 namespace zipios {
00014 
00015 using std::ifstream ;
00016 
00020 class ZipOutputStream : public ostream {
00021 public:
00022 
00026   explicit ZipOutputStream( ostream &os, streampos pos = 0 ) ;
00027 
00031   explicit ZipOutputStream( const string &filename, streampos pos = 0 ) ;
00032   
00037   void closeEntry() ;
00038 
00043   void close() ;
00044 
00049   void finish() ;
00050 
00057   void putNextEntry( const ZipCDirEntry &entry ) ;
00058 
00060   void setComment( const string &comment ) ;
00061 
00063   void setLevel( int level ) ;
00064 
00067   void setMethod( StorageMethod method ) ;
00068 
00070   virtual ~ZipOutputStream() ;
00071 
00072 private:
00073   ofstream *ofs ;
00074   ZipOutputStreambuf *ozf ;
00075 };
00076  
00077 } // namespace.
00078 
00079 #endif
00080 
00085 /*
00086   Zipios++ - a small C++ library that provides easy access to .zip files.
00087   Copyright (C) 2000  Thomas Søndergaard
00088   
00089   This library is free software; you can redistribute it and/or
00090   modify it under the terms of the GNU Lesser General Public
00091   License as published by the Free Software Foundation; either
00092   version 2 of the License, or (at your option) any later version.
00093   
00094   This library is distributed in the hope that it will be useful,
00095   but WITHOUT ANY WARRANTY; without even the implied warranty of
00096   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00097   Lesser General Public License for more details.
00098   
00099   You should have received a copy of the GNU Lesser General Public
00100   License along with this library; if not, write to the Free Software
00101   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
00102 */

Generated at Tue Aug 14 20:39:26 2001 for Zipios++ by doxygen1.2.0 written by Dimitri van Heesch, © 1997-2000