libkmime
kqcstringsplitter.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef KQCSTRINGSPLITTER_H
00018 #define KQCSTRINGSPLITTER_H
00019
00020 #include <qcstring.h>
00021
00022 #include <kdepimmacros.h>
00023
00024 class KDE_EXPORT KQCStringSplitter {
00025
00026 public:
00027 KQCStringSplitter();
00028 ~KQCStringSplitter();
00029
00030 void reset() { start=0; end=0; sep=""; incSep=false;}
00031
00032 void init(const QCString &str, const char *s);
00033 void init(const char *str, const char *s);
00034 void setIncludeSep(bool inc) { incSep=inc; }
00035
00036 bool first();
00037 bool last();
00038
00039 bool next();
00040 bool prev();
00041
00042 QCString& string() { return dst; }
00043 const QCString& source() { return src; }
00044
00045 private:
00046 QCString src, dst, sep;
00047 int start,end;
00048 bool incSep;
00049
00050 };
00051
00052 #endif
|