Changeset 218:66f334ec3256 in documentViewer for documentViewer.py
- Timestamp:
- Oct 8, 2010, 1:09:29 PM (14 years ago)
- Branch:
- default
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
documentViewer.py
r205 r218 533 533 return docinfo 534 534 535 536 def getNameFromIndexMeta(self,path,docinfo=None,dom=None,cut=0): 537 """gets name info from the index.meta file at path or given by dom""" 538 if docinfo is None: 539 docinfo = {} 540 541 if dom is None: 542 for x in range(cut): 543 path=getParentDir(path) 544 dom = self.getDomFromIndexMeta(path) 545 546 docinfo['indexMetaPath']=self.getIndexMetaPath(path); 547 548 result= dom.xpath("//result/resultPage") 549 docinfo['numPages']=int(getTextFromNode(result[0])) 550 551 if len(bibmap) > 0 and len(bibmap['author'][0]) > 0: 552 try: 553 docinfo['name']=getTextFromNode(dom.xpath("//name")) 554 except: pass 555 #logging.debug("documentViewer (getbibinfofromindexmeta) using mapping for %s"%bibtype) 556 return docinfo 535 557 536 558 def getDocinfoFromTextTool(self, url, dom=None, docinfo=None):
Note: See TracChangeset
for help on using the changeset viewer.