Package ca.cgjennings.algo
Interface ProgressListener
-
- All Superinterfaces:
java.util.EventListener
- All Known Implementing Classes:
ProgressBarAdapter,ProgressRangeAdapter
public interface ProgressListener extends java.util.EventListenerAn interface implemented by classes that wish to listen to aMonitoredAlgorithmto be notified when progress is made.- Since:
- 3.0
- Author:
- Chris Jennings
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanprogressUpdate(java.lang.Object source, float progress)Called to indicate that an algorithm has made progress towards completion.
-
-
-
Method Detail
-
progressUpdate
boolean progressUpdate(java.lang.Object source, float progress)Called to indicate that an algorithm has made progress towards completion. If the listener returnstrue, it is a hint that the operation should be cancelled if possible.- Parameters:
source- the source of the progress eventprogress- a value between 0 (none) and 1 (algorithm complete)- Returns:
trueif the callee wishes to hint that the algorithm be cancelled
-
-