Subversion Repositories spk

Rev

Rev 10 | Rev 101 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 10 Rev 98
Line 1... Line 1...
1
 
1
 
2
#include "StringList.h"
2
#include "StringList.h"
-
 
3
#include "spkdef.h"
3
 
4
 
4
namespace Utils {
5
namespace Utils {
5
	void CStringList::pushBack(const String &str, const String &data)
6
	void CStringList::pushBack(const String &str, const String &data)
6
	{
7
	{
7
		SStringList *strNode = new SStringList;
8
		SStringList *strNode = new SStringList;
Line 11... Line 12...
11
	}
12
	}
12
 
13
 
13
	void CStringList::clear()
14
	void CStringList::clear()
14
	{
15
	{
15
		this->destroy(true);
16
		this->destroy(true);
-
 
17
	}
-
 
18
 
-
 
19
	void CStringList::tokenise(const String &str, const String &token)
-
 
20
	{
-
 
21
		int max = 0;
-
 
22
		Utils::String *strs = str.tokenise(token, &max);
-
 
23
		for ( int i = 0; i < max; i++ ) {
-
 
24
			this->pushBack(strs[i], Utils::String::Null());
-
 
25
		}
-
 
26
 
-
 
27
		CLEANSPLIT(strs, max);
-
 
28
	}
-
 
29
 
-
 
30
	Utils::String CStringList::firstString()
-
 
31
	{
-
 
32
		SStringList *node = this->First();
-
 
33
		if ( node ) return node->str;
-
 
34
		return Utils::String::Null();
-
 
35
	}
-
 
36
 
-
 
37
	Utils::String CStringList::nextString()
-
 
38
	{
-
 
39
		SStringList *node = this->Next();
-
 
40
		if ( node ) return node->str;
-
 
41
		return Utils::String::Null();
16
	}
42
	}
17
}
43
}
18
/*
44
/*
19
StringList::StringList(void)
45
StringList::StringList(void)
20
{
46
{