00001 00004 /* Copyright (C) 2007 Olly Betts 00005 * 00006 * This program is free software; you can redistribute it and/or 00007 * modify it under the terms of the GNU General Public License as 00008 * published by the Free Software Foundation; either version 2 of the 00009 * License, or (at your option) any later version. 00010 * 00011 * This program is distributed in the hope that it will be useful, 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 * GNU General Public License for more details. 00015 * 00016 * You should have received a copy of the GNU General Public License 00017 * along with this program; if not, write to the Free Software 00018 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00019 */ 00020 00021 #include <config.h> 00022 00023 #include <xapian/error.h> 00024 00025 #include "postlist.h" 00026 00027 using namespace std; 00028 00029 namespace Xapian { 00030 00031 PostingIterator::Internal::~Internal() { } 00032 00033 Xapian::termcount 00034 PostingIterator::Internal::get_wdf() const 00035 { 00036 throw Xapian::InvalidOperationError("get_wdf() not meaningful for this PostingIterator"); 00037 } 00038 00039 const string * 00040 PostingIterator::Internal::get_collapse_key() const 00041 { 00042 return NULL; 00043 } 00044 00045 PositionList * 00046 PostList::read_position_list() 00047 { 00048 throw Xapian::InvalidOperationError("read_position_list() not meaningful for this PostingIterator"); 00049 } 00050 00051 PositionList * 00052 PostList::open_position_list() const 00053 { 00054 throw Xapian::InvalidOperationError("open_position_list() not meaningful for this PostingIterator"); 00055 } 00056 00057 PostList * 00058 PostList::check(Xapian::docid did, Xapian::weight w_min, bool &valid) 00059 { 00060 valid = true; 00061 return skip_to(did, w_min); 00062 } 00063 00064 }