00001 #ifndef VOCABULARY_H
00002 #define VOCABULARY_H
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #include <tagcoll/TagSet.h>
00025 #include <tagcoll/TagConsumer.h>
00026 #include <tagcoll/ParserBase.h>
00027 #include <tagcoll/DerivedTags.h>
00028
00029 #include <string>
00030 #include <list>
00031 #include <map>
00032
00033 namespace Tagcoll
00034 {
00035 class Facet;
00036 class FacetConsumer;
00037 class FacetFilter;
00038 class TagConsumer;
00039 class TagFilter;
00040 };
00041
00042 namespace Debtags
00043 {
00044 using namespace Tagcoll;
00045
00046 class Vocabulary : public FacetSet
00047 {
00048 protected:
00049 DerivedTagList equations;
00050
00051 public:
00053 const DerivedTagList& getEquations() const throw () { return equations; }
00054
00056 bool hasFacet(const std::string& facet) const throw () { return has(facet); }
00057
00059 Facet findFacet(const std::string& facet) const throw () { return find(facet); }
00060
00062 const FacetSet& getFacets() const throw () { return *this; }
00063
00065 FacetSet getFacets(const FacetMatcher& filter) const throw () { return getFiltered(filter); }
00066
00068 void read(ParserInput& input) throw (ParserException);
00069
00071 void read() throw (FileException, ParserException);
00072
00074 void readVocabularies() throw (SystemException, FileException, ParserException);
00075
00077 void write() throw (FileException);
00078
00079
00080
00081
00082
00083 };
00084
00085 };
00086
00087
00088 #endif