X-Git-Url: http://git.nguyen.vg/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2FXMLDocShredder.h;fp=src%2FXMLDocShredder.h;h=0000000000000000000000000000000000000000;hb=ff13d22656fdbdffb2d909192bd17ba135606224;hp=a12500d2f7192cdd53cc8b714e79da54bb802b64;hpb=d7e793e387b3a59877765e15c54649a9d74d137e;p=SXSI%2Fxpathcomp.git diff --git a/src/XMLDocShredder.h b/src/XMLDocShredder.h deleted file mode 100644 index a12500d..0000000 --- a/src/XMLDocShredder.h +++ /dev/null @@ -1,68 +0,0 @@ -/************************************** - * XMLDocShredder.h - * -------------------- - * Header file for the shredder routine that invokes the XML parser and - * calls the appropriate construction methods of the storage interface in - * correspondence with received parsing events. - * - * Author: Greg Leighton - * Date: 02/11/08 - */ - -#ifndef XMLDOCSHREDDER_H_ -#define XMLDOCSHREDDER_H_ - -#include -#include -#include -#include "XMLTree.h" -#include "XMLTreeBuilder.h" - -using namespace std; -using namespace xmlpp; - - -class XMLDocShredder -{ - void doText(); -public: - XMLDocShredder(const string inFileName,int sf, bool iet, bool dtc, - TextCollectionBuilder::index_type_t index_type - ); - XMLDocShredder(const unsigned char * data, - TextReader::size_type size, - int sf, bool iet, bool dtc, - TextCollectionBuilder::index_type_t index_type - ); - virtual ~XMLDocShredder(); - virtual void processStartElement(); - virtual void processEndElement(); - virtual void processPCDATA(); - virtual void processAttributes(); - virtual void processSignificantWhitespace(); - virtual void processStartDocument(const string docName); - virtual void processEndDocument(); - virtual void processComment(); - virtual void processProcessingInstruction(); - virtual void processDocTypeDeclaration(); - virtual void processUnknownNodeType(); - virtual void processCDATASection(); - virtual void parse(); - - XMLTree * getXMLTree(){ - return tree; - } - - - private: - XMLTreeBuilder * tb; - XMLTree * tree; - TextReader *reader_; - void setProperties(); - bool last_text; - string buffer; - // used to coalece successive text events - // which can occur if we discard pi and comment nodes. -}; - -#endif /*XMLDOCSHREDDER_H_*/