|
a/src/index/exefetcher.h |
|
b/src/index/exefetcher.h |
|
... |
|
... |
21 |
|
21 |
|
22 |
class RclConfig;
|
22 |
class RclConfig;
|
23 |
|
23 |
|
24 |
/**
|
24 |
/**
|
25 |
* A fetcher which works by executing external programs, defined in a
|
25 |
* A fetcher which works by executing external programs, defined in a
|
26 |
* configuration file:
|
26 |
* configuration file.
|
|
|
27 |
* At this point this is only used with the sample python mbox indexer,
|
|
|
28 |
* to show how recoll can work with completely external data extraction code.
|
|
|
29 |
*
|
|
|
30 |
* Configuration: The external indexer sets the 'rclbes' recoll field
|
|
|
31 |
* (backend definition, can be FS or BGL -web- in standard recoll) to
|
|
|
32 |
* a unique value (e.g. MBOX for the python sample). A 'backends' file
|
|
|
33 |
* in the configuration directory then links the 'rclbes' value with
|
|
|
34 |
* commands to execute for fetching the data, which recoll uses at
|
|
|
35 |
* query time for previewing and opening the document.
|
27 |
*/
|
36 |
*/
|
28 |
class EXEDocFetcher : public DocFetcher {
|
37 |
class EXEDocFetcher : public DocFetcher {
|
29 |
class Internal;
|
38 |
class Internal;
|
30 |
EXEDocFetcher(const Internal&);
|
39 |
EXEDocFetcher(const Internal&);
|
31 |
virtual ~EXEDocFetcher() {}
|
40 |
virtual ~EXEDocFetcher() {}
|
32 |
|
41 |
|
33 |
virtual bool fetch(RclConfig* cnf, const Rcl::Doc& idoc, RawDoc& out);
|
42 |
virtual bool fetch(RclConfig* cnf, const Rcl::Doc& idoc, RawDoc& out);
|
34 |
/** Calls stat to retrieve file signature data */
|
43 |
/** Calls stat to retrieve file signature data */
|
35 |
virtual bool makesig(RclConfig* cnf, const Rcl::Doc& idoc, std::string& sig);
|
44 |
virtual bool makesig(RclConfig* cnf, const Rcl::Doc& idoc,std::string& sig);
|
36 |
friend EXEDocFetcher *exeDocFetcherMake(RclConfig *, const std::string&);
|
45 |
friend EXEDocFetcher *exeDocFetcherMake(RclConfig *, const std::string&);
|
37 |
private:
|
46 |
private:
|
38 |
Internal *m;
|
47 |
Internal *m;
|
39 |
};
|
48 |
};
|
40 |
|
49 |
|