summaryrefslogtreecommitdiff
path: root/src/include/util_String.h
blob: 1496b89c7202af40c688edb5654d28c0062e474d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
 /*@@
   @header    util_String.h
   @date      Tue May  2 11:00:39 2000
   @author    Tom Goodale
   @desc 
   String routines
   @enddesc 
   @version $Header$
 @@*/

#include <stdarg.h>

#ifndef _UTIL_STRING_H_
#define _UTIL_STRING_H_ 1

#ifdef __cplusplus
extern "C" 
{
#endif

const char *Util_StrSep(const char **stringp, 
                        const char *delim);

int Util_SplitString(char **before, 
                     char **after, 
                     const char *string, 
                     const char *sep);

int Util_SplitFilename(char **dir, 
                       char **file, 
                       const char *string);

char *Util_Strdup(const char *s);

int Util_StrCmpi(const char *string1, 
                 const char *string2);

int Util_vsnprintf (char *str, size_t count, const char *fmt, va_list args);
int Util_snprintf (char *str,size_t count,const char *fmt,...);

int Util_asprintf(char **buffer, const char *fmt, ...);
int Util_asnprintf(char **buffer, size_t size, const char *fmt, ...);

#ifdef __cplusplus
}
#endif

#endif /* _UTIL_STRING_H_ */