Commit 20640015180ced68ee1941193638202d5e0679d0

Authored by Conrad Vermeulen
1 parent 05aff10c

KTS-673

"The search algorithm needs some work"
Updated.

Committed By: Conrad Vermeulen
Reviewed By: Kevin Fourie

git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@7472 c91229c3-7414-0410-bfa2-8a42b809f60b
search2/indexing/extractors/OOPresentationExtractor.inc.php
1 1 <?php
2 2  
3   -require_once('OOPDFTextExtractor.inc.php');
  3 +require_once('OOTextExtractor.inc.php');
  4 +require_once('PDFExtractor.inc.php');
4 5  
5   -class OOPresentationExtractor extends OOPDFTextExtractor
  6 +class OOPresentationExtractor extends CompositeExtractor
6 7 {
  8 + public function __construct()
  9 + {
  10 + $sourceExtractor = new OOPresentationToPDF();
  11 + $targetExtractor = new PDFExtractor();
  12 + parent::__construct($sourceExtractor, 'pdf', 'application/pdf', $targetExtractor, true);
  13 + }
  14 +
7 15 public function getDisplayName()
8 16 {
9 17 return _kt('OpenOffice Presentation Extractor');
... ... @@ -18,4 +26,18 @@ class OOPresentationExtractor extends OOPDFTextExtractor
18 26 }
19 27 }
20 28  
  29 +class OOPresentationToPDF extends OOTextExtractor
  30 +{
  31 + public function __construct()
  32 + {
  33 + parent::__construct('pdf');
  34 + $this->documentConverter = KT_DIR . '/bin/openoffice/pdfgen.py';
  35 + if (!is_file($this->documentConverter))
  36 + {
  37 + $this->documentConverter = false;
  38 + }
  39 + }
  40 +}
  41 +
  42 +
21 43 ?>
22 44 \ No newline at end of file
... ...