Mercurial > hg > documentViewer
comparison MpdlXmlTextServer.py @ 309:ea18683b2bff
*** empty log message ***
author | abukhman |
---|---|
date | Fri, 15 Oct 2010 12:30:52 +0200 |
parents | bc7c8021a83d |
children | 80ae2324562b |
comparison
equal
deleted
inserted
replaced
308:bc7c8021a83d | 309:ea18683b2bff |
---|---|
154 result = dom.xpath("//result/resultPage/place") | 154 result = dom.xpath("//result/resultPage/place") |
155 for l in result: | 155 for l in result: |
156 hrefNode= l.getAttributeNodeNS(None, u"id") | 156 hrefNode= l.getAttributeNodeNS(None, u"id") |
157 href= hrefNode.nodeValue | 157 href= hrefNode.nodeValue |
158 hrefList.append(href) | 158 hrefList.append(href) |
159 myList = ",".join(hrefList) | 159 myList = ",".join(hrefList) |
160 logging.debug("getGisPlaces :%s"%(myList)) | |
160 return myList | 161 return myList |
161 | |
162 | 162 |
163 def getAllGisPlaces (self, docinfo=None, pageinfo=None): | 163 def getAllGisPlaces (self, docinfo=None, pageinfo=None): |
164 """Show all Gis Places of whole Book """ | 164 """Show all Gis Places of whole Book """ |
165 xpath ='//echo:place' | 165 xpath ='//echo:place' |
166 docpath =docinfo['textURLPath'] | 166 docpath =docinfo['textURLPath'] |
175 for l in result: | 175 for l in result: |
176 hrefNode = l.getAttributeNodeNS(None, u"id") | 176 hrefNode = l.getAttributeNodeNS(None, u"id") |
177 href= hrefNode.nodeValue | 177 href= hrefNode.nodeValue |
178 hrefList.append(href) | 178 hrefList.append(href) |
179 myList = ",".join(hrefList) | 179 myList = ",".join(hrefList) |
180 return myList | 180 logging.debug("getALLGisPlaces :%s"%(myList)) |
181 return myList | |
182 | |
181 | 183 |
182 def getTextPage(self, mode="text", pn=1, docinfo=None, pageinfo=None, highlightQuery=None,sn=None, viewMode=None, tocMode=None, tocPN=None, characterNormalization=""): | 184 def getTextPage(self, mode="text", pn=1, docinfo=None, pageinfo=None, highlightQuery=None,sn=None, viewMode=None, tocMode=None, tocPN=None, characterNormalization=""): |
183 """returns single page from fulltext""" | 185 """returns single page from fulltext""" |
184 docpath = docinfo['textURLPath'] | 186 docpath = docinfo['textURLPath'] |
185 path = docinfo['textURLPath'] | 187 path = docinfo['textURLPath'] |