VHISTlib  1.84.0.3018
/daten/ahuesgen/projects/vhist/code/vhistlib/include/vhistfindlib/vhistfindquery.h
00001 /* $HEADERS
00002  $Id: vhistfindquery.h 2168 2011-05-30 09:09:54Z ahuesgen $
00003  */
00004 
00005 #ifndef FINDQUERY_H
00006 #define FINDQUERY_H
00007 
00008 #include "../shared/misc_defines.h"
00009 #include "../unvhistlib/summary.h"
00010 #include "../unvhistlib/vhistparser.h"
00011 
00012 #include "queryerror.h"
00013 #include "cnf.h"
00014 
00015 #include <QString>
00016 #include <QHash>
00017 
00018 namespace vhist
00019 {
00020 
00026 class VHIST_EXTERN VhistFindQuery
00027 {
00028 public:
00029     VhistFindQuery(const QString& query = "");
00030     ~VhistFindQuery();
00031 
00032 public:
00033     bool setQuery(const QString& query);
00034     bool matches(VhistParser& parser, QHash<QString, QString>*
00035             associations) const;
00036     bool matches(const Summaries& summaries, QHash<QString, QString>*
00037             associations) const;
00038 
00039 public:
00040     bool isValid() const;
00041     QueryErrors getErrors() const;
00042 
00043 private:
00044     QString m_query;
00045     QueryErrors m_errors;
00046     ConjunctiveNormalForm m_cnf;
00047 };
00048 
00049 }
00050 
00051 #endif // FINDQUERY_H

VHISTlib 1.84.0.3018 of Jun 28 2013, generated by doxygen.