MCPcopy Index your code
hub / github.com/pyload/pyload / setRate

Method setRate

module/network/Bucket.py:33–36  ·  view source on GitHub ↗
(self, rate)

Source from the content-addressed store, hash-verified

31 return False if self.rate < 10240 else True
32
33 def setRate(self, rate):
34 self.lock.acquire()
35 self.rate = int(rate)
36 self.lock.release()
37
38 def consumed(self, amount):
39 """ return time the process have to sleep, after consumed specified amount """

Callers 2

updateBucketMethod · 0.80
HTTPDownload.pyFile · 0.80

Calls 2

acquireMethod · 0.80
releaseMethod · 0.45

Tested by

no test coverage detected