#ifndef ACL_STRINGOPS_INCLUDE_H
#define ACL_STRINGOPS_INCLUDE_H

#ifdef  __cplusplus
extern "C" {
#endif

#include "acl_define.h"

/**
 * жϸַǷȫΪ
 * @param str {const char*} ַ
 * @return {int} 0: ; 1: 
 */
ACL_API int acl_alldig(const char *str);

/**
 * жϸַǷΪ
 * @param s {const char*} ַ
 * @return {int} 0: ; 1: 
 */
ACL_API int acl_is_double(const char *s);

/**
 * ַƴӳһַ
 * @param arg0 {const char*} һǿַ
 * @param ... ַϣ NULL
 * @return {char*} ַΪ, ַҪ acl_myfree ͷ
 */
ACL_API char *acl_concatenate(const char *arg0,...);

/**
 * һȫ·ļȡļ֣磺
 *  "/tmp/test.txt"  "\\tmp\\test.txt" ȡ test.txt
 * @param path {const char*} ·ļ磺"/tmp/test.txt"
 *   "\\tmp\\test.txt"
 * @return {const char*} ļ÷ֵҪͷţصĵַ
 *  Ϊմ(һֽΪ '\0') ˵·ļ
 */
ACL_API const char *acl_safe_basename(const char *path);

/**
 * ַзֱָȡ name, value ַ, ַΪ
 * {sp}{name}{sp}={sp}{value}{sp}, ɹ򽫽ֱд洢,
 *  {sp} ַΪ: ո, "\t", "\r", "\n"
 * @param buf {char*} ַ, Ϊ
 * @param name {char**} 洢ĵַָ룬Ϊ
 * @param value {char**} 洢ĵַָ룬Ϊ
 * @param sep {char} ָ
 * @return {const char*} ԭΪʾɹʾʧܲ
 *  ʧԭ
 */
ACL_API const char *acl_split_nameval2(char *buf, char **name, char **value, char sep);

/**
 * ͬ acl_split_nameval2ֻ޶˷ָΪ '='
 * @param buf {char*}
 * @param name {char**}
 * @param value {char**}
 * @return {const char*}
 */
ACL_API const char *acl_split_nameval(char *buf, char **name, char **value);

#ifdef  __cplusplus
}
#endif

#endif

