| 1 |
/* Header for module utility, generated by p2c 1.21alpha-07.Dec.93 */ |
| 2 |
#ifndef UTILITY_H |
| 3 |
#define UTILITY_H |
| 4 |
|
| 5 |
|
| 6 |
#ifdef UTILITY_G |
| 7 |
# define vextern |
| 8 |
#else |
| 9 |
# define vextern extern |
| 10 |
#endif |
| 11 |
/* DPL 2004-03-22 */ |
| 12 |
|
| 13 |
/* Utilities, mainly aids to parsing */ |
| 14 |
|
| 15 |
|
| 16 |
extern boolean equalsIgnoreCase(Char *s1, Char *s2); |
| 17 |
extern boolean startsWithIgnoreCase(Char *s1, Char *s2); |
| 18 |
extern boolean endsWith(Char *s1, Char *s2); |
| 19 |
extern boolean startsWithBracedWord(Char *P); |
| 20 |
extern Char *GetNextWord(Char *Result, Char *s, Char Delim, Char Term); |
| 21 |
extern Char *NextWord(Char *Result, Char *s, Char Delim, Char Term); |
| 22 |
extern short wordCount(Char *s); |
| 23 |
extern Char *plural(Char *Result, short n); |
| 24 |
extern short curtail(Char *s, Char c); |
| 25 |
/* Remove last character if it equals c and return its position; |
| 26 |
otherwise return 0 */ |
| 27 |
extern Char *toString(Char *Result, short n); |
| 28 |
extern void trim(Char *s); |
| 29 |
extern short digit(Char c); |
| 30 |
extern boolean match(Char *source, Char *pattern); |
| 31 |
extern Char *translate(Char *Result, Char *source, Char *pattern, |
| 32 |
Char *target); |
| 33 |
extern void grep(Char *source, Char *pattern, Char *target); |
| 34 |
/* See Implementation for what this currently does. */ |
| 35 |
|
| 36 |
|
| 37 |
#undef vextern |
| 38 |
|
| 39 |
#endif /*UTILITY_H*/ |
| 40 |
|
| 41 |
/* End. */ |