|
a/src/utils/smallut.h |
|
b/src/utils/smallut.h |
|
... |
|
... |
14 |
* Free Software Foundation, Inc.,
|
14 |
* Free Software Foundation, Inc.,
|
15 |
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
15 |
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
16 |
*/
|
16 |
*/
|
17 |
#ifndef _SMALLUT_H_INCLUDED_
|
17 |
#ifndef _SMALLUT_H_INCLUDED_
|
18 |
#define _SMALLUT_H_INCLUDED_
|
18 |
#define _SMALLUT_H_INCLUDED_
|
19 |
/* @(#$Id: smallut.h,v 1.32 2008-11-19 10:06:49 dockes Exp $ (C) 2004 J.F.Dockes */
|
19 |
/* @(#$Id: smallut.h,v 1.33 2008-12-05 07:38:07 dockes Exp $ (C) 2004 J.F.Dockes */
|
20 |
#include <string>
|
20 |
#include <string>
|
21 |
#include <list>
|
21 |
#include <list>
|
22 |
#include <vector>
|
22 |
#include <vector>
|
23 |
#include <map>
|
23 |
#include <map>
|
24 |
#include <set>
|
24 |
#include <set>
|
|
... |
|
... |
46 |
/**
|
46 |
/**
|
47 |
* Parse input string into list of strings.
|
47 |
* Parse input string into list of strings.
|
48 |
*
|
48 |
*
|
49 |
* Token delimiter is " \t\n" except inside dquotes. dquote inside
|
49 |
* Token delimiter is " \t\n" except inside dquotes. dquote inside
|
50 |
* dquotes can be escaped with \ etc...
|
50 |
* dquotes can be escaped with \ etc...
|
|
|
51 |
* Input is handled a byte at a time, things will work as long as space tab etc.
|
|
|
52 |
* have the ascii values and can't appear as part of a multibyte char. utf-8 ok
|
|
|
53 |
* but so are the iso-8859-x and surely others.
|
51 |
*/
|
54 |
*/
|
52 |
extern bool stringToStrings(const string &s, list<string> &tokens);
|
55 |
extern bool stringToStrings(const string &s, list<string> &tokens);
|
53 |
extern bool stringToStrings(const string &s, vector<string> &tokens);
|
56 |
extern bool stringToStrings(const string &s, vector<string> &tokens);
|
54 |
|
57 |
|
55 |
/**
|
58 |
/**
|