~ubuntu-branches/debian/lenny/strigiapplet/lenny

« back to all changes in this revision

Viewing changes to src/streamindexer/pdf/pdfendanalyzer.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Mark Purcell
  • Date: 2007-11-14 21:36:22 UTC
  • mfrom: (1.2.1 upstream) (4.1.7 gutsy)
  • Revision ID: james.westby@ubuntu.com-20071114213622-rxvf3wta16gpmioj
Tags: 0.5.7-1
* New upstream release
* debian/patches/10_desktop_entry_missing_required_key.diff included
  upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
#include <PDFDoc.h>
27
27
#include <TextOutputDev.h>
28
28
 
29
 
using namespace jstreams;
 
29
using namespace Strigi;
30
30
 
31
 
class PdfEndAnalyzer : public jstreams::StreamEndAnalyzer {
 
31
class PdfEndAnalyzer : public StreamEndAnalyzer {
32
32
private:
33
33
    static int objectCount;
34
34
    static void writeText(void *, char *text, int len);
36
36
    PdfEndAnalyzer();
37
37
    ~PdfEndAnalyzer();
38
38
    bool checkHeader(const char* header, int32_t headersize) const;
39
 
    char analyze(std::string filename, jstreams::InputStream *in, int depth,
40
 
        jstreams::StreamIndexer *indexer, jstreams::Indexable*);
41
 
    static char staticAnalyze(std::string filename, jstreams::InputStream *in,
42
 
        int depth, jstreams::StreamIndexer *indexer, jstreams::Indexable*);
 
39
    char analyze(std::string filename, InputStream *in, int depth,
 
40
        StreamIndexer *indexer, jstreams::Indexable*);
 
41
    static char staticAnalyze(std::string filename, InputStream *in,
 
42
        int depth, StreamIndexer *indexer, jstreams::Indexable*);
43
43
    const char* getName() const { return "PdfEndAnalyzer"; }
44
44
};
45
45
 
118
118
}
119
119
char
120
120
PdfEndAnalyzer::analyze(std::string filename, InputStream *in,
121
 
        int depth, StreamIndexer *indexer, jstreams::Indexable* idx) {
 
121
        int depth, StreamIndexer *indexer, Indexable* idx) {
122
122
    int32_t size = 20000;
123
123
    const char* b;
124
124
    int32_t nread = in->read(b, size, size);