libkdenetwork Library API Documentation

kqcstringsplitter.h

00001 /*
00002     kqcstringsplitter.h
00003 
00004     KNode, the KDE newsreader
00005     Copyright (c) 1999-2001 the KNode authors.
00006     See file AUTHORS for details
00007 
00008     This program is free software; you can redistribute it and/or modify
00009     it under the terms of the GNU General Public License as published by
00010     the Free Software Foundation; either version 2 of the License, or
00011     (at your option) any later version.
00012     You should have received a copy of the GNU General Public License
00013     along with this program; if not, write to the Free Software Foundation,
00014     Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, US
00015 */
00016 
00017 #ifndef KQCSTRINGSPLITTER_H
00018 #define KQCSTRINGSPLITTER_H
00019 
00020 #include <qcstring.h>
00021 
00022 
00023 class KQCStringSplitter {
00024   
00025   public:
00026     KQCStringSplitter();
00027     ~KQCStringSplitter();
00028         
00029     void reset()                  { start=0; end=0; sep=""; incSep=false;}
00030     
00031     void init(const QCString &str, const char *s);
00032     void init(const char *str, const char *s);
00033     void setIncludeSep(bool inc)  { incSep=inc; }
00034     
00035     bool first();
00036     bool last();
00037     
00038     bool next();
00039     bool prev();  
00040       
00041     QCString& string()              { return dst; }
00042     const QCString& source()        { return src; }
00043           
00044   private:
00045     QCString src, dst, sep;
00046     int start,end;
00047     bool incSep;
00048       
00049 };
00050 
00051 #endif
KDE Logo
This file is part of the documentation for libkdenetwork Library Version 3.3.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Thu Oct 4 14:39:11 2007 by doxygen 1.4.2 written by Dimitri van Heesch, © 1997-2003