added a test's code it's about SpliteByString.

This commit is contained in:
HuYingzhuo(hugo/hyzboy) 2023-01-04 14:52:29 +08:00
parent 6eb3f9123d
commit 05ab513b8b

View File

@ -21,6 +21,16 @@ int main(int,char **)
UTF8StringList sl;
UTF8String str="hello game world!";
{
UTF8String left,right;
SpliteByString(str, UTF8String("game"), &left, &right);
cout<<"SpliteByString"<<endl;
cout << "left: \"" << left.c_str() <<"\"" << endl;
cout << "right: \""<<right.c_str() <<"\"" << endl;
}
{
SplitToStringListBySpace(sl,str);