--- cdli/cdli_files.py 2007/02/08 12:00:23 1.66 +++ cdli/cdli_files.py 2007/03/19 18:34:01 1.67 @@ -1537,6 +1537,16 @@ class CDLIFileFolder(extVersionedFileFol return ret + def getFile(self,fn): + """get the content of the file fn""" + founds=self.CDLICatalog.search({'title':fn}) + if not founds: + return [] + else: + obj=founds[0].getObject().getLastVersion() + logging.error(obj.getData()) + return obj.getData()[0:] + def checkCatalog(self,fn): """check if fn is in the catalog""" #TODO add checkCatalog @@ -1559,7 +1569,13 @@ class CDLIFileFolder(extVersionedFileFol return pt(search=list,author=author) - + def getAllPNumbers(self): + """get a list of all files (resp their p-numbers) stored""" + + ret=[x.getId for x in self.CDLICatalog()] + + return ret + def findObjectsFromList(self,enterList=None,display=False,start=None,upload=None,list=None,basketName=None,numberOfObjects=None,RESPONSE=None): """findObjectsFromList (, TAB oder LINE separated)"""