|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.jhu.ece.iacl.jist.pipeline.AbstractCalculation
public abstract class AbstractCalculation
Observable Calculation allows a calculation to be monitored.
Field Summary | |
---|---|
protected CalculationMonitor |
monitor
monitor to track current thread. |
Constructor Summary | |
---|---|
AbstractCalculation()
Default constructor. |
|
AbstractCalculation(AbstractCalculation parent)
Constructor with parent calculation. |
Method Summary | |
---|---|
void |
add(AbstractCalculation child)
Add a child calculation to this calculation. |
void |
addTotalUnits(long extra)
Add extra computational units to the total computational units. |
void |
decrementCompletedUnits()
Decrement the number of completed units. |
void |
decrementCompletedUnits(int inc)
Decrement the number of completed units. |
long |
getCompletedUnits()
Completed computational units for the calculation. |
java.lang.String |
getCurrentLabel()
Get current label of calculation including any child calculations in progress. |
double |
getCurrentProgress()
Return normalized progress of deepest child calculation. |
java.lang.String |
getLabel()
Label for this computation. |
PerformanceSummary |
getPerformance()
Get performance summary. |
double |
getProgress()
Return normalized progress of this calculation. |
long |
getTotalUnits()
Total computational units for calculation. |
void |
incrementCompletedUnits()
Increment the number of completed units. |
void |
incrementCompletedUnits(int inc)
Increment the number of completed units. |
boolean |
isCompleted()
True if completed units equals total computational units. |
void |
markCompleted()
Mark algorithm as completed at the end of calculation It is mandatory that this method be executed at the end of the calculation. |
void |
reset()
Reset the completed units for this calculation and all child calculations. |
void |
setCompletedUnits(double percent)
Set the percent completed [0,1] Requires that the total number of units is non-zero, (i.e. |
void |
setCompletedUnits(int units)
Set the number of units completed. |
void |
setLabel(java.lang.String str)
Set label to display in progress bar for this calculation. |
void |
setMonitor(CalculationMonitor monitor)
Set monitor that observes this calculation. |
void |
setTotalUnits(long total)
Set total computational units for this calculation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected CalculationMonitor monitor
Constructor Detail |
---|
public AbstractCalculation()
public AbstractCalculation(AbstractCalculation parent)
parent
- parent calculationMethod Detail |
---|
public void add(AbstractCalculation child)
child
- the childpublic void addTotalUnits(long extra)
extra
- the extra completed unitspublic void decrementCompletedUnits()
public void decrementCompletedUnits(int inc)
inc
- increment amountpublic long getCompletedUnits()
public java.lang.String getCurrentLabel()
public double getCurrentProgress()
public java.lang.String getLabel()
public PerformanceSummary getPerformance()
public double getProgress()
public long getTotalUnits()
public void incrementCompletedUnits()
public void incrementCompletedUnits(int inc)
inc
- incrementpublic boolean isCompleted()
public void markCompleted()
public void reset()
public void setCompletedUnits(double percent)
percent
- the percentpublic void setCompletedUnits(int units)
units
- the unitspublic void setLabel(java.lang.String str)
str
- the stringpublic void setMonitor(CalculationMonitor monitor)
monitor
- the monitorpublic void setTotalUnits(long total)
total
- the total
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |