fastdo  0.6.16
strings.hpp 文件参考
#include <stdarg.h>
strings.hpp 的引用(Include)关系图:
此图展示该文件直接或间接的被哪些文件引用了:

浏览源代码.

class  winux::XStringWriter< _ChTy >
 用来使得String能够用operator<<来赋值 更多...
 
class  winux::MultiMatch
 多项匹配/替换 更多...
 
struct  winux::MultiMatch::MatchResult
 
struct  winux::MultiMatch::MatchState
 
class  winux::Locale
 设置locale信息 更多...
 
class  winux::SZInput
 填充based-zero字符串缓冲区包装类 更多...
 
class  winux::Conv
 字符串编码转换 更多...
 
class  winux::ConvTo< _ToString >
 本地编码转到指定编码 更多...
 
class  winux::ConvFrom< _FromString >
 指定编码转到本地编码 更多...
 
class  winux::UnicodeConverter
 Unicode转换器。可以使UTF-8、UTF-16、UTF-32字符串相互自由转换,字节序为平台默认 更多...
 

命名空间

 winux
 跨平台基础功能库
 

宏定义

#define SZP   SZInput
 如果操作对象是缓冲区指针,则使用SZP宏 更多...
 
#define u8(s)   winux::UnicodeConverter(s).toUtf8()
 
#define L(s)   winux::UnicodeConverter(s).toUnicode()
 
#define u(s)   winux::UnicodeConverter(s).toUtf16()
 
#define U(s)   winux::UnicodeConverter(s).toUtf32()
 
#define LOCAL_FROM_UTF8(s)   s
 
#define LOCAL_TO_UTF8(s)   s
 

类型定义

using winux::StringWriter = XStringWriter< tchar >
 
using winux::AnsiStringWriter = XStringWriter< char >
 
using winux::UnicodeStringWriter = XStringWriter< wchar >
 
using winux::UnicodeString16Writer = XStringWriter< char16 >
 
using winux::Utf16StringWriter = XStringWriter< char16 >
 
using winux::UnicodeString32Writer = XStringWriter< char32 >
 
using winux::Utf32StringWriter = XStringWriter< char32 >
 
using winux::UC = UnicodeConverter
 UnicodeConverter简单别名 更多...
 

枚举

enum  winux::StrToXqFlags { winux::stqUnsigned = 1, winux::stqNegative = 2, winux::stqOverflow = 4, winux::stqReadDigit = 8 }
 字符串转换成数字Flags 更多...
 
enum  winux::CollateIdentifierStringFlag : winux::uint {
  winux::wordRaw = 0x00, winux::wordAllUpper = 0x01, winux::wordAllLower = 0x02, winux::wordFirstCharUpper = 0x03,
  winux::nameLowerCamelCase = 0x10 | wordFirstCharUpper, winux::nameUpperCamelCase = 0x20 | wordFirstCharUpper, winux::namePascalCase = nameUpperCamelCase, winux::nameSnakeCase = 0x30 | wordAllLower,
  winux::nameKebabCase = 0x40 | wordAllLower, winux::nameScreamingSnakeCase = 0x50 | wordAllUpper
}
 整理标识符串的标记 更多...
 

函数

template<typename _ChTy >
static XString< _ChTy > winux::CharSeqToString (_ChTy const *str, size_t len=npos)
 C字符串转到XString. 更多...
 
template<typename _RetChTy , typename _ChTy = _RetChTy>
static XString< _RetChTy > winux::CharToHexStr (_ChTy ch, bool padZero=false)
 字符转成16进制串形式 更多...
 
template<typename _ChTy >
size_t winux::StrSplit (XString< _ChTy > const &str, XString< _ChTy > const &delimList, XStringArray< _ChTy > *arr, bool alwaysRetOneElem=false)
 
template<>
size_t winux::StrSplit (XString< char > const &str, XString< char > const &delimList, XStringArray< char > *arr, bool alwaysRetOneElem)
 
template<>
size_t winux::StrSplit (XString< wchar > const &str, XString< wchar > const &delimList, XStringArray< wchar > *arr, bool alwaysRetOneElem)
 
template<>
size_t winux::StrSplit (XString< char16 > const &str, XString< char16 > const &delimList, XStringArray< char16 > *arr, bool alwaysRetOneElem)
 
template<>
size_t winux::StrSplit (XString< char32 > const &str, XString< char32 > const &delimList, XStringArray< char32 > *arr, bool alwaysRetOneElem)
 
size_t winux::StrSplit (AnsiString const &str, AnsiString const &delimList, AnsiStringArray *arr, bool alwaysRetOneElem=false)
 字符串分割 更多...
 
template<typename _ChTy >
XStringArray< _ChTy > winux::StrSplit (XString< _ChTy > const &str, XString< _ChTy > const &delimList, bool alwaysRetOneElem=false)
 
template<>
XStringArray< char > winux::StrSplit (XString< char > const &str, XString< char > const &delimList, bool alwaysRetOneElem)
 
template<>
XStringArray< wchar > winux::StrSplit (XString< wchar > const &str, XString< wchar > const &delimList, bool alwaysRetOneElem)
 
template<>
XStringArray< char16 > winux::StrSplit (XString< char16 > const &str, XString< char16 > const &delimList, bool alwaysRetOneElem)
 
template<>
XStringArray< char32 > winux::StrSplit (XString< char32 > const &str, XString< char32 > const &delimList, bool alwaysRetOneElem)
 
AnsiStringArray winux::StrSplit (AnsiString const &str, AnsiString const &delimList, bool alwaysRetOneElem=false)
 字符串分割 更多...
 
template<typename _ChTy >
size_t winux::StrSplit2 (XString< _ChTy > const &str, XString< _ChTy > const &delim, XStringArray< _ChTy > *arr, bool alwaysRetOneElem=false)
 
template<>
size_t winux::StrSplit2 (XString< char > const &str, XString< char > const &delim, XStringArray< char > *arr, bool alwaysRetOneElem)
 
template<>
size_t winux::StrSplit2 (XString< wchar > const &str, XString< wchar > const &delim, XStringArray< wchar > *arr, bool alwaysRetOneElem)
 
template<>
size_t winux::StrSplit2 (XString< char16 > const &str, XString< char16 > const &delim, XStringArray< char16 > *arr, bool alwaysRetOneElem)
 
template<>
size_t winux::StrSplit2 (XString< char32 > const &str, XString< char32 > const &delim, XStringArray< char32 > *arr, bool alwaysRetOneElem)
 
size_t winux::StrSplit2 (AnsiString const &str, AnsiString const &delim, AnsiStringArray *arr, bool alwaysRetOneElem=false)
 字符串分割2 更多...
 
template<typename _ChTy >
XStringArray< _ChTy > winux::StrSplit2 (XString< _ChTy > const &str, XString< _ChTy > const &delim, bool alwaysRetOneElem=false)
 
template<>
XStringArray< char > winux::StrSplit2 (XString< char > const &str, XString< char > const &delim, bool alwaysRetOneElem)
 
template<>
XStringArray< wchar > winux::StrSplit2 (XString< wchar > const &str, XString< wchar > const &delim, bool alwaysRetOneElem)
 
template<>
XStringArray< char16 > winux::StrSplit2 (XString< char16 > const &str, XString< char16 > const &delim, bool alwaysRetOneElem)
 
template<>
XStringArray< char32 > winux::StrSplit2 (XString< char32 > const &str, XString< char32 > const &delim, bool alwaysRetOneElem)
 
AnsiStringArray winux::StrSplit2 (AnsiString const &str, AnsiString const &delim, bool alwaysRetOneElem=false)
 字符串分割2 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StrJoin (XString< _ChTy > const &delim, XStringArray< _ChTy > const &arr)
 
template<>
XString< char > winux::StrJoin (XString< char > const &delim, XStringArray< char > const &arr)
 
template<>
XString< wchar > winux::StrJoin (XString< wchar > const &delim, XStringArray< wchar > const &arr)
 
template<>
XString< char16 > winux::StrJoin (XString< char16 > const &delim, XStringArray< char16 > const &arr)
 
template<>
XString< char32 > winux::StrJoin (XString< char32 > const &delim, XStringArray< char32 > const &arr)
 
AnsiString winux::StrJoin (AnsiString const &delim, AnsiStringArray const &arr)
 字符串组合连接 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StrJoinEx (XString< _ChTy > const &delim, XStringArray< _ChTy > const &arr, size_t start=0, size_t elemCount=-1)
 
template<>
XString< char > winux::StrJoinEx (XString< char > const &delim, XStringArray< char > const &arr, size_t start, size_t elemCount)
 
template<>
XString< wchar > winux::StrJoinEx (XString< wchar > const &delim, XStringArray< wchar > const &arr, size_t start, size_t elemCount)
 
template<>
XString< char16 > winux::StrJoinEx (XString< char16 > const &delim, XStringArray< char16 > const &arr, size_t start, size_t elemCount)
 
template<>
XString< char32 > winux::StrJoinEx (XString< char32 > const &delim, XStringArray< char32 > const &arr, size_t start, size_t elemCount)
 
AnsiString winux::StrJoinEx (AnsiString const &delim, AnsiStringArray const &arr, size_t start=0, size_t elemCount=-1)
 字符串组合连接。start表示开始位置,elemCount表示自开始位置的元素数,默认-1表示自开始位置的全部元素 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StrInsert (XString< _ChTy > const &str, size_t start, size_t end, XString< _ChTy > const &insert)
 
template<>
XString< char > winux::StrInsert (XString< char > const &str, size_t start, size_t end, XString< char > const &insert)
 
template<>
XString< wchar > winux::StrInsert (XString< wchar > const &str, size_t start, size_t end, XString< wchar > const &insert)
 
template<>
XString< char16 > winux::StrInsert (XString< char16 > const &str, size_t start, size_t end, XString< char16 > const &insert)
 
template<>
XString< char32 > winux::StrInsert (XString< char32 > const &str, size_t start, size_t end, XString< char32 > const &insert)
 
AnsiString winux::StrInsert (AnsiString const &str, size_t start, size_t end, AnsiString const &insert)
 在指定位置插入字符串 更多...
 
template<typename _ChTy >
XString< _ChTy > & winux::StrMakeReplace (XString< _ChTy > *str, XString< _ChTy > const &findText, XString< _ChTy > const &replaceText, size_t offset=0)
 
template<>
XString< char > & winux::StrMakeReplace (XString< char > *str, XString< char > const &findText, XString< char > const &replaceText, size_t offset)
 
template<>
XString< wchar > & winux::StrMakeReplace (XString< wchar > *str, XString< wchar > const &findText, XString< wchar > const &replaceText, size_t offset)
 
template<>
XString< char16 > & winux::StrMakeReplace (XString< char16 > *str, XString< char16 > const &findText, XString< char16 > const &replaceText, size_t offset)
 
template<>
XString< char32 > & winux::StrMakeReplace (XString< char32 > *str, XString< char32 > const &findText, XString< char32 > const &replaceText, size_t offset)
 
AnsiString & winux::StrMakeReplace (AnsiString *str, AnsiString const &findText, AnsiString const &replaceText, size_t offset=0)
 使字符串全文替换 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StrTrim (XString< _ChTy > const &str, size_t *leftSpaceCount=nullptr, size_t *rightSpaceCount=nullptr)
 
template<>
XString< char > winux::StrTrim (XString< char > const &str, size_t *leftSpaceCount, size_t *rightSpaceCount)
 
template<>
XString< wchar > winux::StrTrim (XString< wchar > const &str, size_t *leftSpaceCount, size_t *rightSpaceCount)
 
template<>
XString< char16 > winux::StrTrim (XString< char16 > const &str, size_t *leftSpaceCount, size_t *rightSpaceCount)
 
template<>
XString< char32 > winux::StrTrim (XString< char32 > const &str, size_t *leftSpaceCount, size_t *rightSpaceCount)
 
template<typename _ChTy >
XString< _ChTy > winux::StrLTrim (XString< _ChTy > const &str, size_t *leftSpaceCount=nullptr)
 
template<>
XString< char > winux::StrLTrim (XString< char > const &str, size_t *leftSpaceCount)
 
template<>
XString< wchar > winux::StrLTrim (XString< wchar > const &str, size_t *leftSpaceCount)
 
template<>
XString< char16 > winux::StrLTrim (XString< char16 > const &str, size_t *leftSpaceCount)
 
template<>
XString< char32 > winux::StrLTrim (XString< char32 > const &str, size_t *leftSpaceCount)
 
template<typename _ChTy >
XString< _ChTy > winux::StrRTrim (XString< _ChTy > const &str, size_t *rightSpaceCount=nullptr)
 
template<>
XString< char > winux::StrRTrim (XString< char > const &str, size_t *rightSpaceCount)
 
template<>
XString< wchar > winux::StrRTrim (XString< wchar > const &str, size_t *rightSpaceCount)
 
template<>
XString< char16 > winux::StrRTrim (XString< char16 > const &str, size_t *rightSpaceCount)
 
template<>
XString< char32 > winux::StrRTrim (XString< char32 > const &str, size_t *rightSpaceCount)
 
AnsiString winux::StrTrim (AnsiString const &str, size_t *leftSpaceCount=nullptr, size_t *rightSpaceCount=nullptr)
 祛除字符串首尾出现的空白字符 更多...
 
AnsiString winux::StrLTrim (AnsiString const &str, size_t *leftSpaceCount=nullptr)
 
AnsiString winux::StrRTrim (AnsiString const &str, size_t *rightSpaceCount=nullptr)
 
template<typename _ChTy >
XString< _ChTy > & winux::StrMakeUpper (XString< _ChTy > *str)
 
template<>
XString< char > & winux::StrMakeUpper (XString< char > *str)
 
template<>
XString< wchar > & winux::StrMakeUpper (XString< wchar > *str)
 
template<>
XString< char16 > & winux::StrMakeUpper (XString< char16 > *str)
 
template<>
XString< char32 > & winux::StrMakeUpper (XString< char32 > *str)
 
AnsiString & winux::StrMakeUpper (AnsiString *str)
 使字符串大写 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StrUpper (XString< _ChTy > str)
 
template<>
XString< char > winux::StrUpper (XString< char > str)
 
template<>
XString< wchar > winux::StrUpper (XString< wchar > str)
 
template<>
XString< char16 > winux::StrUpper (XString< char16 > str)
 
template<>
XString< char32 > winux::StrUpper (XString< char32 > str)
 
AnsiString winux::StrUpper (AnsiString str)
 使字符串大写 更多...
 
template<typename _ChTy >
XString< _ChTy > & winux::StrMakeLower (XString< _ChTy > *str)
 
template<>
XString< char > & winux::StrMakeLower (XString< char > *str)
 
template<>
XString< wchar > & winux::StrMakeLower (XString< wchar > *str)
 
template<>
XString< char16 > & winux::StrMakeLower (XString< char16 > *str)
 
template<>
XString< char32 > & winux::StrMakeLower (XString< char32 > *str)
 
AnsiString & winux::StrMakeLower (AnsiString *str)
 使字符串小写 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StrLower (XString< _ChTy > str)
 
template<>
XString< char > winux::StrLower (XString< char > str)
 
template<>
XString< wchar > winux::StrLower (XString< wchar > str)
 
template<>
XString< char16 > winux::StrLower (XString< char16 > str)
 
template<>
XString< char32 > winux::StrLower (XString< char32 > str)
 
AnsiString winux::StrLower (AnsiString str)
 使字符串小写 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StrMultiple (XString< _ChTy > const &str, size_t multiple)
 
template<>
XString< char > winux::StrMultiple (XString< char > const &str, size_t multiple)
 
template<>
XString< wchar > winux::StrMultiple (XString< wchar > const &str, size_t multiple)
 
template<>
XString< char16 > winux::StrMultiple (XString< char16 > const &str, size_t multiple)
 
template<>
XString< char32 > winux::StrMultiple (XString< char32 > const &str, size_t multiple)
 
AnsiString winux::StrMultiple (AnsiString const &str, size_t multiple)
 字符串倍数的出现 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StrSubtract (XString< _ChTy > str1, XString< _ChTy > const &str2)
 
template<>
XString< char > winux::StrSubtract (XString< char > str1, XString< char > const &str2)
 
template<>
XString< wchar > winux::StrSubtract (XString< wchar > str1, XString< wchar > const &str2)
 
template<>
XString< char16 > winux::StrSubtract (XString< char16 > str1, XString< char16 > const &str2)
 
template<>
XString< char32 > winux::StrSubtract (XString< char32 > str1, XString< char32 > const &str2)
 
AnsiString winux::StrSubtract (AnsiString str1, AnsiString const &str2)
 字符串相减,str1 - str2,即去掉str1里与str2相同的部分。限制:str1 >= str2。 更多...
 
template<typename _ChTy >
uint64 winux::StrToXq (_ChTy const *nptr, _ChTy const **endptr, int ibase, int flags)
 
template<>
uint64 winux::StrToXq (char const *nptr, char const **endptr, int ibase, int flags)
 字符串转换成64位的数字 更多...
 
template<>
uint64 winux::StrToXq (wchar const *nptr, wchar const **endptr, int ibase, int flags)
 
template<>
uint64 winux::StrToXq (char16 const *nptr, char16 const **endptr, int ibase, int flags)
 
template<>
uint64 winux::StrToXq (char32 const *nptr, char32 const **endptr, int ibase, int flags)
 
template<typename _ChTy >
int64 winux::StrToInt64 (XString< _ChTy > const &numStr, int ibase)
 
template<>
int64 winux::StrToInt64 (XString< char > const &numStr, int ibase)
 
template<>
int64 winux::StrToInt64 (XString< wchar > const &numStr, int ibase)
 
template<>
int64 winux::StrToInt64 (XString< char16 > const &numStr, int ibase)
 
template<>
int64 winux::StrToInt64 (XString< char32 > const &numStr, int ibase)
 
int64 winux::StrToInt64 (AnsiString const &numStr, int ibase)
 
template<typename _ChTy >
uint64 winux::StrToUInt64 (XString< _ChTy > const &numStr, int ibase)
 
template<>
uint64 winux::StrToUInt64 (XString< char > const &numStr, int ibase)
 
template<>
uint64 winux::StrToUInt64 (XString< wchar > const &numStr, int ibase)
 
template<>
uint64 winux::StrToUInt64 (XString< char16 > const &numStr, int ibase)
 
template<>
uint64 winux::StrToUInt64 (XString< char32 > const &numStr, int ibase)
 
uint64 winux::StrToUInt64 (AnsiString const &numStr, int ibase)
 
template<typename _ChTy >
XString< _ChTy > winux::AddSlashes (XString< _ChTy > const &str, XString< _ChTy > const &charlist)
 
template<>
XString< char > winux::AddSlashes (XString< char > const &str, XString< char > const &charlist)
 
template<>
XString< wchar > winux::AddSlashes (XString< wchar > const &str, XString< wchar > const &charlist)
 
template<>
XString< char16 > winux::AddSlashes (XString< char16 > const &str, XString< char16 > const &charlist)
 
template<>
XString< char32 > winux::AddSlashes (XString< char32 > const &str, XString< char32 > const &charlist)
 
AnsiString winux::AddSlashes (AnsiString const &str, AnsiString const &charlist)
 加反斜杠 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::AddCSlashes (XString< _ChTy > const &str)
 
AnsiString winux::AddCSlashes (AnsiString const &str)
 加C-Style反斜杠 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StripSlashes (XString< _ChTy > const &str, XString< _ChTy > const &charlist)
 
template<>
XString< char > winux::StripSlashes (XString< char > const &str, XString< char > const &charlist)
 
template<>
XString< wchar > winux::StripSlashes (XString< wchar > const &str, XString< wchar > const &charlist)
 
template<>
XString< char16 > winux::StripSlashes (XString< char16 > const &str, XString< char16 > const &charlist)
 
template<>
XString< char32 > winux::StripSlashes (XString< char32 > const &str, XString< char32 > const &charlist)
 
AnsiString winux::StripSlashes (AnsiString const &str, AnsiString const &charlist)
 去掉反斜杠 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::StripCSlashes (XString< _ChTy > const &str)
 
AnsiString winux::StripCSlashes (AnsiString const &str)
 去掉C-Style反斜杠 更多...
 
template<typename _ChTy >
XString< _ChTy > winux::AddQuotes (XString< _ChTy > const &str, _ChTy quote=Literal< _ChTy >::quoteChar)
 
template<>
XString< char > winux::AddQuotes (XString< char > const &str, char quote)
 
template<>
XString< wchar > winux::AddQuotes (XString< wchar > const &str, wchar quote)
 
template<>
XString< char16 > winux::AddQuotes (XString< char16 > const &str, char16 quote)
 
template<>
XString< char32 > winux::AddQuotes (XString< char32 > const &str, char32 quote)
 
AnsiString winux::AddQuotes (AnsiString const &str, AnsiString::value_type quote=Literal< AnsiString::value_type >::quoteChar)
 double引号 更多...
 
template<typename _ChTy >
bool winux::StrGetLine (XString< _ChTy > *line, XString< _ChTy > const &str, size_t *i, XString< _ChTy > *nl=nullptr)
 
template<>
bool winux::StrGetLine (XString< char > *line, XString< char > const &str, size_t *i, XString< char > *nl)
 
template<>
bool winux::StrGetLine (XString< wchar > *line, XString< wchar > const &str, size_t *i, XString< wchar > *nl)
 
template<>
bool winux::StrGetLine (XString< char16 > *line, XString< char16 > const &str, size_t *i, XString< char16 > *nl)
 
template<>
bool winux::StrGetLine (XString< char32 > *line, XString< char32 > const &str, size_t *i, XString< char32 > *nl)
 
bool winux::StrGetLine (AnsiString *line, AnsiString const &str, size_t *i, AnsiString *nl=nullptr)
 获取字符串中的一行。支持unix,windows,mac平台的行分隔方式
更多...
 
template<typename _ChTy >
bool winux::StrGetLine (XString< _ChTy > *line, _ChTy const *str, size_t len, size_t *i, XString< _ChTy > *nl=nullptr)
 
template<>
bool winux::StrGetLine (XString< char > *line, char const *str, size_t len, size_t *i, XString< char > *nl)
 
template<>
bool winux::StrGetLine (XString< wchar > *line, wchar const *str, size_t len, size_t *i, XString< wchar > *nl)
 
template<>
bool winux::StrGetLine (XString< char16 > *line, char16 const *str, size_t len, size_t *i, XString< char16 > *nl)
 
template<>
bool winux::StrGetLine (XString< char32 > *line, char32 const *str, size_t len, size_t *i, XString< char32 > *nl)
 
bool winux::StrGetLine (AnsiString *line, AnsiString::value_type const *str, size_t len, size_t *i, AnsiString *nl=nullptr)
 获取字符串中的一行。支持unix,windows,mac平台的行分隔方式
更多...
 
template<typename _ChTy >
void winux::GetLineByPos (XString< _ChTy > const &content, ssize_t pos, ssize_t *lineHead, ssize_t *lineTail, XString< _ChTy > *line=nullptr)
 获取指定位置的行内容 更多...
 
template<>
void winux::GetLineByPos (XString< char > const &content, ssize_t pos, ssize_t *lineHead, ssize_t *lineTail, XString< char > *line)
 
template<>
void winux::GetLineByPos (XString< wchar > const &content, ssize_t pos, ssize_t *lineHead, ssize_t *lineTail, XString< wchar > *line)
 
template<>
void winux::GetLineByPos (XString< char16 > const &content, ssize_t pos, ssize_t *lineHead, ssize_t *lineTail, XString< char16 > *line)
 
template<>
void winux::GetLineByPos (XString< char32 > const &content, ssize_t pos, ssize_t *lineHead, ssize_t *lineTail, XString< char32 > *line)
 
template<typename _ChTy >
XString< _ChTy > winux::CollateIdentifierToString (XString< _ChTy > const &identifier, XString< _ChTy > const &sep, winux::uint flags=wordFirstCharUpper)
 
template<>
XString< char > winux::CollateIdentifierToString (XString< char > const &identifier, XString< char > const &sep, winux::uint flags)
 
template<>
XString< wchar > winux::CollateIdentifierToString (XString< wchar > const &identifier, XString< wchar > const &sep, winux::uint flags)
 
template<>
XString< char16 > winux::CollateIdentifierToString (XString< char16 > const &identifier, XString< char16 > const &sep, winux::uint flags)
 
template<>
XString< char32 > winux::CollateIdentifierToString (XString< char32 > const &identifier, XString< char32 > const &sep, winux::uint flags)
 
AnsiString winux::CollateIdentifierToString (AnsiString const &identifier, AnsiString const &sep, winux::uint flags=wordFirstCharUpper)
 整理标识符为字符串 更多...
 
template<typename _ChTy >
XStringArray< _ChTy > winux::CollateIdentifierToArray (XString< _ChTy > const &identifier, winux::uint flags=wordFirstCharUpper)
 
template<>
XStringArray< char > winux::CollateIdentifierToArray (XString< char > const &identifier, winux::uint flags)
 
template<>
XStringArray< wchar > winux::CollateIdentifierToArray (XString< wchar > const &identifier, winux::uint flags)
 
template<>
XStringArray< char16 > winux::CollateIdentifierToArray (XString< char16 > const &identifier, winux::uint flags)
 
template<>
XStringArray< char32 > winux::CollateIdentifierToArray (XString< char32 > const &identifier, winux::uint flags)
 
AnsiStringArray winux::CollateIdentifierToArray (AnsiString const &identifier, winux::uint flags=wordFirstCharUpper)
 整理标识符为单词数组 更多...
 
template<typename _IndexType , typename _ChTy >
static std::vector< _IndexType > winux::_Templ_KmpCalcNext (_ChTy const *substr, size_t sublen)
 KMP匹配算法:求子串next值 更多...
 
template<typename _IndexType , typename _ChTy >
static size_t winux::_Templ_KmpMatchEx (_ChTy const *str, size_t len, _ChTy const *substr, size_t sublen, size_t pos, std::vector< _IndexType > const &next)
 KMP匹配算法:传入已经求好的next进行匹配 更多...
 
template<typename _IndexType , typename _ChTy >
static size_t winux::_Templ_KmpMatch (_ChTy const *str, size_t len, _ChTy const *substr, size_t sublen, size_t pos)
 KMP匹配算法:匹配 更多...
 
template<typename _ChTy >
std::vector< int > winux::KmpCalcNext (_ChTy const *substr, size_t sublen)
 KMP字符串匹配算法:求子串next值 更多...
 
template<typename _ChTy >
size_t winux::KmpMatchEx (_ChTy const *str, size_t len, _ChTy const *substr, size_t sublen, size_t pos, std::vector< int > const &next)
 KMP字符串匹配算法:传入已经求好的next进行匹配 更多...
 
template<typename _ChTy >
size_t winux::KmpMatch (_ChTy const *str, size_t len, _ChTy const *substr, size_t sublen, size_t pos)
 KMP字符串匹配算法:匹配 更多...
 
size_t winux::LocalCharsCount (AnsiString const &local)
 返回一个本地字符串里有多少个实际的字符(by local CodePage),用于mbstowcs 更多...
 
size_t winux::UnicodeMinLength (UnicodeString const &unicode)
 返回一个unicode字符串转换为多字节字符串最少需要多少字节(by local CodePage),用于wcstombs 更多...
 
AnsiString winux::UnicodeToLocal (UnicodeString const &unicode)
 Unicode转换到本地Ansi. 更多...
 
UnicodeString winux::LocalToUnicode (AnsiString const &local)
 本地Ansi转到Unicode 更多...
 
String winux::LocalToString (AnsiString const &local)
 兼容字符串与Unicode、Local字符串相互转换 更多...
 
String winux::UnicodeToString (UnicodeString const &unicode)
 兼容字符串与Unicode、Local字符串相互转换 更多...
 
AnsiString winux::StringToLocal (String const &str)
 兼容字符串与Unicode、Local字符串相互转换 更多...
 
UnicodeString winux::StringToUnicode (String const &str)
 兼容字符串与Unicode、Local字符串相互转换 更多...
 
AnsiString winux::FormatExVA (size_t cch, char const *fmt, va_list args)
 
UnicodeString winux::FormatExVW (size_t cch, wchar const *fmt, va_list args)
 
AnsiString winux::FormatExA (size_t cch, char const *fmt,...)
 
UnicodeString winux::FormatExW (size_t cch, wchar const *fmt,...)
 
AnsiString winux::FormatA (char const *fmt,...)
 
UnicodeString winux::FormatW (wchar const *fmt,...)
 
AnsiString winux::FormatExV (size_t cch, char const *fmt, va_list args)
 格式化字符串0 更多...
 
AnsiString winux::FormatEx (size_t cch, char const *fmt,...)
 格式化字符串1 更多...
 
AnsiString winux::Format (char const *fmt,...)
 格式化字符串2 更多...
 
template<typename _CHAR , uint _Count>
SZInput winux::SZ (_CHAR(&sz)[_Count])
 VC2010以上支持模板取数组大小 更多...
 
static AnsiString winux::LocalFromUtf8 (AnsiString const &str)
 从utf-8转到本地编码 更多...
 
static AnsiString winux::LocalToUtf8 (AnsiString const &str)
 从本地编码转到utf-8 更多...
 

宏定义说明

#define SZP   SZInput

如果操作对象是缓冲区指针,则使用SZP宏

在文件 strings.hpp1016 行定义.

#define u8 (   s)    winux::UnicodeConverter(s).toUtf8()

在文件 strings.hpp1138 行定义.

#define L (   s)    winux::UnicodeConverter(s).toUnicode()

在文件 strings.hpp1139 行定义.

#define u (   s)    winux::UnicodeConverter(s).toUtf16()

在文件 strings.hpp1140 行定义.

#define U (   s)    winux::UnicodeConverter(s).toUtf32()

在文件 strings.hpp1141 行定义.

#define LOCAL_FROM_UTF8 (   s)    s

在文件 strings.hpp1158 行定义.

#define LOCAL_TO_UTF8 (   s)    s

在文件 strings.hpp1159 行定义.