]> git.lyx.org Git - lyx.git/blob - src/Thesaurus.h
Regenerate lib/CREDITS.
[lyx.git] / src / Thesaurus.h
1 // -*- C++ -*-
2 /**
3  * \file Thesaurus.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author John Levon
8  * \author Jürgen Spitzmüller
9  *
10  * Full author contact details are available in file CREDITS.
11  */
12
13 #ifndef THESAURUS_H
14 #define THESAURUS_H
15
16 #include "support/docstring.h"
17 #include "WordLangTuple.h"
18
19 #include <map>
20 #include <string>
21 #include <vector>
22
23 namespace lyx {
24
25 /**
26  * This class provides an interface to whatever thesauri we might support.
27  */
28
29 class Thesaurus
30 {
31 public:
32         ///
33         Thesaurus();
34         ///
35         ~Thesaurus();
36
37         typedef std::map<docstring, std::vector<docstring> > Meanings;
38
39         /**
40          * look up some text in the thesaurus
41          */
42         Meanings lookup(WordLangTuple const & wl);
43         /** check if a thesaurus for a given language \p lang is available
44          *  (installed and loaded)
45          */
46         bool thesaurusAvailable(docstring const & lang) const;
47         /// check if a thesaurus for a given language \p lang is installed
48         bool thesaurusInstalled(docstring const & lang) const;
49
50 private:
51         struct Private;
52         Private * const d;
53 };
54
55 extern Thesaurus thesaurus;
56
57
58 } // namespace lyx
59
60 #endif