Mercurial > hg > documentViewer
comparison MpdlXmlTextServer.py @ 195:2c2dcfbb701c
*** empty log message ***
author | abukhman |
---|---|
date | Tue, 05 Oct 2010 12:38:17 +0200 |
parents | 490a0a1a65d7 |
children | 60c98265a8dd |
comparison
equal
deleted
inserted
replaced
194:490a0a1a65d7 | 195:2c2dcfbb701c |
---|---|
134 # allredy there | 134 # allredy there |
135 return docinfo | 135 return docinfo |
136 xpath ='/count(//pb)' | 136 xpath ='/count(//pb)' |
137 text=self.getServerData("xpath.xql", "document=%s&xpath=%s"%(docinfo['textURLPath'], xpath)) | 137 text=self.getServerData("xpath.xql", "document=%s&xpath=%s"%(docinfo['textURLPath'], xpath)) |
138 logging.debug("documentViewer (text) text: %s"%(text)) | 138 logging.debug("documentViewer (text) text: %s"%(text)) |
139 docinfo['numPages']=text.xpath(resultPage) | 139 docinfo['numPages']=text('resultPage') |
140 #logging.debug("documentViewer (characterNormalization) characterNormalization: %s"%(characterNormalization)) | 140 logging.debug("documentViewer (characterNormalization) docinfo['numPages']: %s"%(docinfo['numPages'])) |
141 return docinfo | 141 return docinfo |
142 | 142 |
143 def getTextPage(self, mode="text", pn=1, docinfo=None, pageinfo=None, highlightQuery=None,sn=None, viewMode=None, tocMode=None, tocPN=None, characterNormalization=""): | 143 def getTextPage(self, mode="text", pn=1, docinfo=None, pageinfo=None, highlightQuery=None,sn=None, viewMode=None, tocMode=None, tocPN=None, characterNormalization=""): |
144 """returns single page from fulltext""" | 144 """returns single page from fulltext""" |
145 docpath = docinfo['textURLPath'] | 145 docpath = docinfo['textURLPath'] |