Main Page   Modules   File List  

cxstrutils.h

00001 /* $Id: cxstrutils.h,v 1.2.2.2 2003/12/15 14:32:33 cizzo Exp $
00002  *
00003  *   This file is part of the ESO Common Pipeline Library
00004  *   Copyright (C) 2001-2003 European Southern Observatory
00005  *
00006  *   This program is free software; you can redistribute it and/or modify
00007  *   it under the terms of the GNU General Public License as published by
00008  *   the Free Software Foundation; either version 2 of the License, or
00009  *   (at your option) any later version.
00010  *
00011  *   This program is distributed in the hope that it will be useful,
00012  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014  *   GNU General Public License for more details.
00015  *
00016  *   You should have received a copy of the GNU General Public License
00017  *   along with this program; if not, write to the Free Software
00018  *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00019  */
00020 
00021 /*
00022  * $Author: cizzo $
00023  * $Date: 2003/12/15 14:32:33 $
00024  * $Revision: 1.2.2.2 $
00025  * $Name: cpl-1_0_1 $
00026  */
00027 
00028 #ifndef CX_STRUTILS_H
00029 #define CX_STRUTILS_H
00030 
00031 #include <stdarg.h>
00032 #include <cxtypes.h>
00033 
00034 CX_BEGIN_DECLS
00035 
00036 /*
00037  * String comparison functions.
00038  */
00039 
00040 cxint cx_strcasecmp(const cxchar *, const cxchar *);
00041 cxint cx_strncasecmp(const cxchar *, const cxchar *, cxsize);
00042 cxint cx_strempty(const cxchar *, const cxchar *);
00043 
00044 
00045 /*
00046  * Utility functions modifing their string argument
00047  */
00048 
00049 cxchar *cx_strlower(cxchar *);
00050 cxchar *cx_strupper(cxchar *);
00051 
00052 cxchar *cx_strtrim(cxchar *);
00053 cxchar *cx_strrtrim(cxchar *);
00054 cxchar *cx_strstrip(cxchar *);
00055 
00056 
00057 /*
00058  * Utility functions which do not create a new string
00059  */
00060 
00061 cxchar *cx_strskip(const cxchar *, cxint (*)(cxint));
00062 
00063 
00064 /*
00065  * Utilities returning a newly allocated string.
00066  */
00067 
00068 cxchar *cx_strdup(const cxchar *);
00069 cxchar *cx_strndup(const cxchar *, cxsize);
00070 cxchar *cx_strvdupf(const cxchar *, va_list);
00071 
00072 cxchar *cx_stpcpy(cxchar *, const cxchar *);
00073 
00074 cxchar **cx_strsplit(const cxchar *, const cxchar *, cxint);
00075 void     cx_strfreev(cxchar **sarray);
00076 
00077 cxchar *cx_strjoinv(const cxchar *, cxchar **);
00078 
00079 CX_END_DECLS
00080 
00081 #endif /* CX_STRUTILS_H */

Generated on Mon May 24 14:58:00 2004 for C Standard Library Extensions by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002