def get_bucket_num(self):
return int(self._read_attr('bucket_num'))
- remote_get_bucket_num = get_bucket_num
def read(self):
return self._read_attr('data')
def callRemote(self, methname, **kwargs):
if methname == "write":
return defer.maybeDeferred(self.write, **kwargs)
- elif methname == "set_size":
- return defer.maybeDeferred(self.set_size, **kwargs)
elif methname == "close":
return defer.maybeDeferred(self.close, **kwargs)
else:
def write(self, data):
self.data.write(data)
- def set_size(self, size):
- self.size = size
def close(self):
self.done = True