![]() |
Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members
![]() |
00001 /******************************************************************************** 00002 * * 00003 * G Z S t r e a m C l a s s e s * 00004 * * 00005 ********************************************************************************* 00006 * Copyright (C) 2002 by Sander Jansen. All Rights Reserved. * 00007 ********************************************************************************* 00008 * This library is free software; you can redistribute it and/or * 00009 * modify it under the terms of the GNU Lesser General Public * 00010 * License as published by the Free Software Foundation; either * 00011 * version 2.1 of the License, or (at your option) any later version. * 00012 * * 00013 * This library is distributed in the hope that it will be useful, * 00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * 00016 * Lesser General Public License for more details. * 00017 * * 00018 * You should have received a copy of the GNU Lesser General Public * 00019 * License along with this library; if not, write to the Free Software * 00020 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * 00021 ********************************************************************************* 00022 * $Id: FXGzStream.h,v 1.6 2002/04/09 23:06:47 fox Exp $ * 00023 ********************************************************************************/ 00024 #ifdef HAVE_ZLIB_H 00025 #ifndef FXGZSTREAM_H 00026 #define FXGZSTREAM_H 00027 00028 #ifndef FXSTREAM_H 00029 #include "FXStream.h" 00030 #endif 00031 00032 ////////////////////////////// UNDER DEVELOPMENT ////////////////////////////// 00033 00034 namespace FX { 00035 00036 00037 /// GZIP compressed stream 00038 class FXAPI FXGzFileStream : public FXStream { 00039 void *gzfile; 00040 protected: 00041 virtual void saveItems(const void *buf,unsigned long n); 00042 virtual void loadItems(void *buf,unsigned long n); 00043 public: 00044 00045 /// Create GZIP compressed file stream 00046 FXGzFileStream(const FXObject* cont=NULL); 00047 00048 /// Open file stream 00049 FXbool open(const char* filename,FXStreamDirection save_or_load); 00050 00051 /// Close file stream 00052 FXbool close(); 00053 00054 /// Move to position 00055 virtual FXbool position(unsigned long p){ return FALSE; } 00056 00057 /// Clean up 00058 virtual ~FXGzFileStream(); 00059 }; 00060 00061 } 00062 00063 00064 #endif 00065 #endif