/*<html><pre>*/
#ifndef	V_STR_H
#define	V_STR_H

/*
 *	Paranoidal string-handling routines.
 */
#ifdef	__cplusplus
extern	"C" {
#endif	/* __cplusplus */
	/*
	 *	strCopy - analog to strncpy.
	 *	Differences:
	 *	1. Remember: third parameter is AMOUNT OF MEMORY allocated for 'dst'.
	 *	2. 'Dst' is ALWAYS terminated by null-character ('\0').
	 *	3. Strings 'dst' and 'src' can be overlapped.
	 *	4. Ifdef CHECKED_BUILD and dst==NULL, default static buffer returned.
	 */
	char_p	V_GLOBAL	strCopy(char_p dst,char_p src,
		int dest_storage_length);
	/*
	 *	strCat - analog to strncat.
	 *	Differences:
	 *	1. Strings 'dst' and 'src' can be overlapped.
	 *	2. Ifdef CHECHED_BUILD and dst==NULL, default static buffer returned.
	 */
	char_p	V_GLOBAL	strCat(char_p dst,char_p src,
		int max_chars_to_be_added);
	/*
	 *	Strips leading whitespace from string. Returns str.
	 *	Note. Ifdef CHECHED_BUILD and str==NULL, default static buffer returned.
	 */
	char_p	V_GLOBAL	strStripLead(char_p str);
	/*
	 *	Strips trailing whitespace from string. Returns str.
	 *	Note. Ifdef CHECHED_BUILD and str==NULL, default static buffer returned.
	 */
	char_p	V_GLOBAL	strStripTrail(char_p str);
	/*
	 *	Strips both leading and trailing whitespace. Returns str.
	 *	Note. Ifdef CHECHED_BUILD and str==NULL, default static buffer returned.
	 */
	char_p	V_GLOBAL	strStripLT(char_p str);
	/*
	 *	Optionally converts dos path to unix path and appends '/' at end
	 *	if no one. Result NEVER exceed _MAX_PATH.
	 */
	char_p	V_GLOBAL	strAppendSlash(char_p path_to_check);
	/*
	 *	Returns integer value of given hexadecimal number.
	 *	Sets *'errchar' (which can be NULL) to 0 on success; otherwise,
	 *	*'errchar' contains first (from TAIL) unrecognized character.
	 */
	u32_t	V_GLOBAL	strHexToDigit(char *str,char *errchar);
	/*	Analog of strdup(), but allocates memory vie memAlloc(). */
	char_p	V_GLOBAL	strDup(char *src);
	/*	Returns original string if not NULL;
	 *	otherwise returns static trash */
	char_p	V_GLOBAL	dbs(char_p string_which_can_be_NULL);
	/* Converts string to lower case using RTL tolower() call */
	char_p	V_GLOBAL	strLower(char *str);
#ifdef	__WATCOMC__
    int strcasecmp(const char *s1,const char *s2);
	int strncasecmp(const char *s1,const char *s2,size_t n);
#endif	/* __WATCOMC__ */
#ifdef	__cplusplus
}
#endif	/* __cplusplus */

#endif	/* V_STR_H */
/*</pre></html>*/
/*EOF*/
