soprano/queryresultiterator.h

Go to the documentation of this file.
00001 /*
00002  * This file is part of Soprano Project.
00003  *
00004  * Copyright (C) 2006 Daniele Galdi <daniele.galdi@gmail.com>
00005  * Copyright (C) 2007 Sebastian Trueg <trueg@kde.org>
00006  *
00007  * This library is free software; you can redistribute it and/or
00008  * modify it under the terms of the GNU Library General Public
00009  * License as published by the Free Software Foundation; either
00010  * version 2 of the License, or (at your option) any later version.
00011  *
00012  * This library is distributed in the hope that it will be useful,
00013  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00014  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00015  * Library General Public License for more details.
00016  *
00017  * You should have received a copy of the GNU Library General Public License
00018  * along with this library; see the file COPYING.LIB.  If not, write to
00019  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00020  * Boston, MA 02110-1301, USA.
00021  */
00022 
00023 #ifndef SOPRANO_RESULT_SET_H
00024 #define SOPRANO_RESULT_SET_H
00025 
00026 #include "iterator.h"
00027 #include "bindingset.h"
00028 #include "soprano_export.h"
00029 
00030 #include <QtCore/QString>
00031 #include <QtCore/QStringList>
00032 
00033 
00034 namespace Soprano {
00035 
00036     class Node;
00037     class NodeIterator;
00038     class QueryResultIteratorBackend;
00039     class Statement;
00040     class StatementIterator;
00041     class BindingSet;
00042 
00099     class SOPRANO_EXPORT QueryResultIterator : public Iterator<BindingSet>
00100     {
00101     public:
00103 
00106         QueryResultIterator();
00107 
00111         QueryResultIterator( const QueryResultIterator& );
00112 
00117         QueryResultIterator( QueryResultIteratorBackend *qr );
00118 
00122         virtual ~QueryResultIterator();
00123 
00127         QueryResultIterator& operator=( const QueryResultIterator& );
00129 
00131 
00135         Statement currentStatement() const;
00136 
00141         BindingSet currentBindings() const;
00142 
00150         bool boolValue() const;
00152 
00154 
00164         Node binding( const QString &name ) const;
00165 
00176         Node binding( int offset ) const;
00177 
00185         int bindingCount() const;
00186 
00192         QStringList bindingNames() const;
00194 
00196 
00202         bool isGraph() const;
00203 
00210         bool isBinding() const;
00211 
00221         bool isBool() const;
00223 
00225 
00229         QList<BindingSet> allBindings();
00230 
00240         StatementIterator iterateStatements() const;
00241 
00254         NodeIterator iterateBindings( const QString& variableName ) const;
00255 
00268         NodeIterator iterateBindings( int offset ) const;
00270     };
00271 }
00272 
00273 #endif // SOPRANO_RESULT_SET_H

Generated on Fri Mar 7 19:00:11 2008 for Soprano by  doxygen 1.5.4