コード例 #1
0
    def stat(self, path):
        path = self._splitpath(path)

        try:
            with self._walk(path) as fid:
                resp = self._dorpc(fcall.Tstat(fid=fid))
                st = resp.stat
                self._clunk(fid)
            return st
        except RPCError:
            return None
コード例 #2
0
 def stat(self):
     resp = self._dorpc(fcall.Tstat())
     return resp.stat
コード例 #3
0
    def stat(self, callback):
        def next(resp, exc, tb):
            callback(resp.stat, exc, tb)

        resp = self._dorpc(fcall.Tstat(), next, callback)
コード例 #4
0
        def next(fid, exc, tb):
            def next(resp, exc, tb):
                callback(resp.stat, exc, tb)

            self._dorpc(fcall.Tstat(fid=fid), next, callback)