00001 00004 /* Copyright 2009 Lemur Consulting Ltd 00005 * Copyright 2009 Olly Betts 00006 * 00007 * This program is free software; you can redistribute it and/or 00008 * modify it under the terms of the GNU General Public License as 00009 * published by the Free Software Foundation; either version 2 of the 00010 * License, or (at your option) any later version. 00011 * 00012 * This program 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 00015 * GNU General Public License for more details. 00016 * 00017 * You should have received a copy of the GNU General Public License 00018 * along with this program; if not, write to the Free Software 00019 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00020 */ 00021 00022 #ifndef XAPIAN_INCLUDED_REGISTRYINTERNAL_H 00023 #define XAPIAN_INCLUDED_REGISTRYINTERNAL_H 00024 00025 #include "xapian/base.h" 00026 #include "xapian/registry.h" 00027 00028 #include <map> 00029 #include <string> 00030 00031 namespace Xapian { 00032 class Weight; 00033 class PostingSource; 00034 class MatchSpy; 00035 } 00036 00037 class Xapian::Registry::Internal : public Xapian::Internal::RefCntBase { 00038 friend class Xapian::Registry; 00039 00041 std::map<std::string, Xapian::Weight *> wtschemes; 00042 00044 std::map<std::string, Xapian::PostingSource *> postingsources; 00045 00047 std::map<std::string, Xapian::MatchSpy *> matchspies; 00048 00050 void add_defaults(); 00051 00053 void clear_weighting_schemes(); 00054 00056 void clear_posting_sources(); 00057 00059 void clear_match_spies(); 00060 00061 public: 00062 Internal(); 00063 ~Internal(); 00064 }; 00065 00066 #endif // XAPIAN_INCLUDED_REGISTRYINTERNAL_H