00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef KDE_SLP_FILTERS_H
00022 #define KDE_SLP_FILTERS_H
00023
00024 #include <kde/util/smartptr.h>
00025 #include <qstring.h>
00026 #include <qvaluelist.h>
00027
00028 namespace KDE {
00029 namespace SLP {
00030
00036 class Filter {
00037 public:
00041 enum Type {
00042 InvalidFilter,
00043 PredicateFilter
00044
00045
00046
00047 };
00048
00049 protected:
00051 Type m_type;
00053 Filter(Type type);
00054
00055 public:
00060 typedef QValueList<KDE::Util::SmartPtr<Filter> > List;
00061
00066 Type type() const { return m_type; }
00067 };
00068
00115 class PredicateFilter : public Filter {
00116 private:
00117 QString m_predicate;
00118 public:
00123 PredicateFilter(const QString &predicate);
00124
00129 QString predicate() const;
00130
00141 static QString escape(const QString &s);
00142 };
00143
00144
00145 }
00146 }
00147
00148 #endif