コード例 #1
0
 def size(self, fn):  # type: (unicode) -> bool
     collection, rest = self.get_collection(fn)
     if collection is not None:
         if rest:
             arvfile = collection.find(rest)
             if isinstance(arvfile, arvados.arvfile.ArvadosFile):
                 return arvfile.size()
         raise IOError(errno.EINVAL, "Not a path to a file %s" % (fn))
     else:
         return super(CollectionFsAccess, self).size(fn)
コード例 #2
0
ファイル: fsaccess.py プロジェクト: chapmanb/arvados
 def size(self, fn):  # type: (unicode) -> bool
     collection, rest = self.get_collection(fn)
     if collection is not None:
         if rest:
             arvfile = collection.find(rest)
             if isinstance(arvfile, arvados.arvfile.ArvadosFile):
                 return arvfile.size()
         raise IOError(errno.EINVAL, "Not a path to a file %s" % (fn))
     else:
         return super(CollectionFsAccess, self).size(fn)