Main Page   Data Structures   File List   Data Fields   Globals   Related Pages  

misc.h

Go to the documentation of this file.
00001 /***************************************************************************
00002                                    misc.h
00003                              -------------------
00004     begin                : Sun Dec 09 2001
00005     copyright            : (C) 2001-2002 by Christian Hoenig & Gunter Ohrner
00006     email                : pdepp@CustomCDROM.de
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00023 #ifndef MISC_H_FLAG
00024 #define MISC_H_FLAG
00025 
00026 #include "common.h"
00027 
00028 #include <stdio.h>
00029 
00031 #define MAX(a,b) (((a) >= (b)) ? (a) : (b))
00032 
00033 #define MAX2(a,b) (MAX((a), (b)))
00034 
00036 #define MAX3(a,b,c) (MAX2(MAX2((a), (b)), (c)))
00037 
00039 #define MAX4(a,b,c,d) (MAX2(MAX3((a), (b), (c)), (d)))
00040 
00042 #define MIN(a, b)         MIN2(a, b)
00043 
00044 #define MIN2(a, b)        (((a) < (b))? (a): (b))
00045 
00046 #define MIN3(a, b, c)     MIN2(a, MIN2(b, c))
00047 
00048 #define MIN4(a, b, c, d)  MIN2(a, MIN3(b, c, d))
00049 
00050 
00063 int getNextValue(int *beg, int *end, unsigned int from, const char *str);
00064 
00075 char* getLine(FILE* file);
00076 
00077 #endif

Generated on Fri Jan 25 22:40:31 2002 for PDepp Webserver by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001