开发者

Is there a tokenizer function written in C that can do what boost::escaped_list_separator does?

I am looking for a stand alone tokenizer written in C that can parse and split strings based on user supplied character separator such as tabs, semi colons, commas etc. Similar to what this boost library function does

http://www.boost.org/doc/libs/1_46_1/libs/tokenizer/escaped_list_separator.htm

The tokens may be double quoted and the separators may be embedded, em开发者_Go百科pty tokens are not skipped


You can use strtok in string.h. You certainly will have to adapt it to manage specifics. As it is C, be careful about null-terminated strings.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜