|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--lima.observation.ObservableBase
|
+--lima.distribution.CompositeWorkUnit
CompositeWorkUnit is a type of workunit that processes its member workunits serially.
It reduces network issues with small workunits.
STATUS: Written, not tested - pw
| Nested Class Summary | |
class |
CompositeWorkUnit.ProgressEvent
|
| Field Summary | |
int |
mynum
|
| Constructor Summary | |
CompositeWorkUnit(lima.distribution.WorkUnit[] members)
Create a workUnit that will process all of members. |
|
| Method Summary | |
int |
cost()
Guess how long this workunit will take to run, in ms on a midrange machine |
boolean |
equals(java.lang.Object o)
|
void |
generateHashCode()
WHAT DOES THIS DO? WHY? - pw |
lima.distribution.WorkUnit[] |
getMembers()
Gets all the workunits that this workunit will/has processed. |
int |
hashcode()
|
boolean |
hasRun()
Returns true iff run has completed on this workUnit. |
void |
run(lima.storage.Cache c)
Start processing this WorkUnit. |
int |
runtime()
How long this WorkUnit took to run in ms. |
java.lang.String |
toString()
|
| Methods inherited from class lima.observation.ObservableBase |
clearObservers, notifyObservers, registerObserver, unregisterObserver |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public final int mynum
| Constructor Detail |
public CompositeWorkUnit(lima.distribution.WorkUnit[] members)
members - - The workUnits to process.| Method Detail |
public void generateHashCode()
WorkUnit
generateHashCode in interface WorkUnitpublic void run(lima.storage.Cache c)
WorkUnit
run in interface WorkUnitdistribute.WorkUnit#run()public lima.distribution.WorkUnit[] getMembers()
public int cost()
WorkUnit
cost in interface WorkUnitdistribute.WorkUnit#cost()
public int runtime()
throws java.lang.IllegalStateException
WorkUnit
runtime in interface WorkUnitjava.lang.IllegalStateException - iff run has not been called.WorkUnit.runtime()public boolean hasRun()
WorkUnit
hasRun in interface WorkUnitWorkUnit.hasRun()public boolean equals(java.lang.Object o)
equals in class java.lang.ObjectObject.equals(java.lang.Object)public int hashcode()
public java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||