/[cvs]/api/Classes/Examples/String/StringTest5.cpp
ViewVC logotype

Annotation of /api/Classes/Examples/String/StringTest5.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1.1.1 - (hide annotations) (vendor branch)
Sun Jul 1 20:47:58 2001 UTC (23 years ago) by bearsoft
Branch: lazy, MAIN
CVS Tags: start, HEAD
Changes since 1.1: +0 -0 lines
First import

1 bearsoft 1.1 #include "../../String/String.h"
2     #include "../../String/StringInput.h"
3     #include "../../System/System.h"
4     #include "StringTest5.h"
5     #include "../../System/SystemDefine.h"
6    
7     StringTest5::StringTest5(){}
8     StringTest5::~StringTest5(){}
9    
10     void StringTest5::run()
11     {
12     StringInput *stringInput=new StringInput();
13    
14     stringInput->readFile("data/test.txt");
15    
16     // stringInput->dontDefragMemory(1000); // select this if you want to have intern word buffer == less malloc, free
17    
18     String kalle="kalle";
19    
20     if (stringInput->findWord(kalle.buffer))
21     {
22     System::println("true");
23     }
24    
25     stringInput->resetScanWord(); //moves the pointer to the begining of the string buffer again
26    
27     delete stringInput;
28    
29    
30    
31     }

root@recompile.se
ViewVC Help
Powered by ViewVC 1.1.26