autodoc.git
/
modref
/
ex
/
predef_3A_3A
/
ADT
/
Scheduler.html
version
»
Context lines:
10
20
40
80
file
none
3
autodoc.git/modref/ex/predef_3A_3A/ADT/Scheduler.html:58:
border="0" alt="next" ></a> </div> </nav> </div> <div class="contentbox"> <article> <h1>Class ADT.Scheduler</h1> <dt class='head--doc'>Inheritance graph</dt>
-
<div class='inheritance-graph'><svg xmlns='http://www.w3.org/2000/svg' version='1.1' xmlns:xlink='http://www.w3.org/1999/xlink' xml:space='preserve' width='100%' height='
45px
'>
+
<div class='inheritance-graph'><svg xmlns='http://www.w3.org/2000/svg' version='1.1' xmlns:xlink='http://www.w3.org/1999/xlink' xml:space='preserve' width='100%' height='
65px
'>
<text x='0' y='20'><a class='ms reference' xlink:href='../../predef_3A_3A/ADT/Heap.html'>ADT.Heap</a></text> <line x1='4' y1='35' x2='35' y2='35' /> <line x1='5' y1='25' x2='5' y2='36' /> <text x='40' y='40'><tspan style='font-family:monospace; font-weight:bold;'>ADT.Scheduler</tspan></text>
-
+
<line x1='45' y1='45' x2='45' y2='56' />
+
<line x1='44' y1='55' x2='75' y2='55' />
+
<text x='80' y='60'><a class='ms reference' xlink:href='../../predef_3A_3A/ADT/TreeScheduler.html'>ADT.TreeScheduler</a></text>
</svg></div> <dl class='group--doc'> <dt class='head--doc'>Description</dt> <dd class='body--doc'><p>This class implements a quantized resource scheduler.</p> <p> Weighted consumers are added to the scheduler with <a class='ms reference' href='../../predef_3A_3A/ADT/Scheduler/add.html'>add()</a>, which returns a <a class='ms reference' href='../../predef_3A_3A/ADT/Scheduler/Consumer.html'>Consumer</a> object.</p> <p> When there's some of the resource available to be consumed the resource owner calls <a class='ms reference' href='../../predef_3A_3A/ADT/Scheduler/get.html'>get()</a>, which returns the <a class='ms reference' href='../../predef_3A_3A/ADT/Scheduler/Consumer.html'>Consumer</a> that is to use the resource. <a class='ms reference' href='../../predef_3A_3A/ADT/Scheduler/Consumer/consume.html'>Consumer()->consume()</a> is then called with the fraction of the quanta that was consumed