00001 /*! \file 00002 * X-Forge Util <br> 00003 * Copyright 2000-2003 Fathammer Ltd 00004 * 00005 * \brief This is a helper hack header file to turn sources using 00006 * FILE * into our XFuFile class friendly ones. 00007 * 00008 * $Id: XFuFileDef.h,v 1.5 2003/03/20 13:19:59 jetro Exp $ 00009 * $Date: 2003/03/20 13:19:59 $ 00010 * $Revision: 1.5 $ 00011 */ 00012 00013 #ifndef XFUFILEDEF_H_INCLUDED 00014 #define XFUFILEDEF_H_INCLUDED 00015 00016 00017 //! Turns fopen() call into XFcFile::open() call. 00018 #define fopen(a, b) XFcFile::open((const CHAR *)(a), XFCSTR(b)) 00019 //! Turns fseek() call into XFcFile::seek() call. 00020 #define fseek(f, a, b) (f) ? f->seek(a, b) : 0 00021 //! Turns ftell() call into XFcFile::tell() call. 00022 #define ftell(f) (f) ? f->tell() : 0 00023 //! Turns fgetc() call into XFcFile::getChar() call. 00024 #define fgetc(f) (f) ? f->getChar() : 0 00025 //! Turns fputc() call into XFcFile::putChar() call. 00026 #define fputc(c, f) (f) ? f->putChar(c) : 0 00027 //! Turns fread() call into XFcFile::read() call. 00028 #define fread(bf, a, b, f) (f) ? f->read(bf, a, b) : 0 00029 //! Turns fwrite() call into XFcFile::write() call. 00030 #define fwrite(bf, a, b, f) (f) ? f->write(bf, a, b) : 0 00031 //! Turns fclose() call into XFcFile::close() call. 00032 #define fclose(f) (f) ? f->close() : 0 00033 //! Turns FILE variable into a XFcFile call. 00034 #define FILE XFcFile 00035 00036 00037 #endif // !XFUFILEDEF_H_INCLUDED
![]() | ||||
![]() |
Confidential Copyright © 2002-2003 Fathammer | with doxygen by Dimitri van Heesch |