LibreOffice Module helpcompiler (master) 1
|
#include <HelpIndexer.hxx>
Public Member Functions | |
HelpIndexer (OUString lang, OUString module, std::u16string_view srcDir, std::u16string_view outDir) | |
bool | indexDocuments () |
Run the indexer. More... | |
OUString const & | getErrorMessage () const |
Get the error string (empty if no error occurred). More... | |
Private Member Functions | |
bool | scanForFiles () |
Scan the caption & contents directories for help files. More... | |
bool | scanForFiles (OUString const &path) |
Scan for files in the given directory. More... | |
void | helpDocument (OUString const &fileName, lucene::document::Document *doc) const |
Fill the Document with information on the given help file. More... | |
Static Private Member Functions | |
static lucene::util::Reader * | helpFileReader (OUString const &path) |
Create a reader for the given file, and create an "empty" reader in case the file doesn't exist. More... | |
Private Attributes | |
OUString | d_lang |
OUString | d_module |
OUString | d_captionDir |
OUString | d_contentDir |
OUString | d_indexDir |
OUString | d_error |
std::set< OUString > | d_files |
Definition at line 33 of file HelpIndexer.hxx.
HelpIndexer::HelpIndexer | ( | OUString | lang, |
OUString | module, | ||
std::u16string_view | srcDir, | ||
std::u16string_view | outDir | ||
) |
lang | Help files language. |
module | The module of the helpfiles. |
srcDir | The help directory to index |
outDir | The directory to write the "module".idxl directory to |
Definition at line 33 of file HelpIndexer.cxx.
References d_captionDir, d_contentDir, d_indexDir, d_module, and module.
|
inline |
Get the error string (empty if no error occurred).
Definition at line 63 of file HelpIndexer.hxx.
Referenced by main().
|
private |
Fill the Document with information on the given help file.
Definition at line 163 of file HelpIndexer.cxx.
References d_captionDir, d_contentDir, d_module, URLEncoder::encode(), Field, helpFileReader(), and OUStringToTCHARVec().
Referenced by indexDocuments().
|
staticprivate |
Create a reader for the given file, and create an "empty" reader in case the file doesn't exist.
Definition at line 183 of file HelpIndexer.cxx.
References OUStringToOString().
Referenced by helpDocument().
bool HelpIndexer::indexDocuments | ( | ) |
Run the indexer.
Definition at line 74 of file HelpIndexer.cxx.
References d_error, d_files, d_indexDir, d_lang, Document, o3tl::getToken(), helpDocument(), OUStringToOString(), o3tl::runtimeToOUString(), scanForFiles(), and u.
Referenced by main().
|
private |
Scan the caption & contents directories for help files.
Definition at line 133 of file HelpIndexer.cxx.
References d_captionDir, d_contentDir, and scanForFiles().
Referenced by indexDocuments(), and scanForFiles().
|
private |
Scan for files in the given directory.
Definition at line 143 of file HelpIndexer.cxx.
|
private |
Definition at line 37 of file HelpIndexer.hxx.
Referenced by helpDocument(), HelpIndexer(), and scanForFiles().
|
private |
Definition at line 38 of file HelpIndexer.hxx.
Referenced by helpDocument(), HelpIndexer(), and scanForFiles().
|
private |
Definition at line 40 of file HelpIndexer.hxx.
Referenced by indexDocuments(), and scanForFiles().
|
private |
Definition at line 41 of file HelpIndexer.hxx.
Referenced by indexDocuments(), and scanForFiles().
|
private |
Definition at line 39 of file HelpIndexer.hxx.
Referenced by HelpIndexer(), and indexDocuments().
|
private |
Definition at line 35 of file HelpIndexer.hxx.
Referenced by indexDocuments().
|
private |
Definition at line 36 of file HelpIndexer.hxx.
Referenced by helpDocument(), and HelpIndexer().