public class ProgressAccumulator extends DefaultProgressReporter implements ProgressListener
ProgressReporter
'sConstructor and Description |
---|
ProgressAccumulator() |
Modifier and Type | Method and Description |
---|---|
void |
addProgressReporter(ProgressReporter reporter)
Add progress reporter with default weight of
1 . |
void |
addProgressReporter(ProgressReporter reporter,
double weight)
Add progress
reporter with given weight . |
void |
addProgressReporter(ProgressReporter reporter,
double weight,
java.lang.String message)
Add progress
reporter with given weight . |
double |
getMinimumChange() |
void |
progressNotification(ProgressEvent event)
sent to this listener new progress event.
|
void |
removeAllProgressReporter() |
void |
removeProgressReporter(ProgressReporter reporter) |
void |
setMinimumChange(double minimumChange) |
addProgressListener, currentProgress, notifyProgressListeners, notifyProgressListeners, notifyProgressListeners, removeAllProgressListener, removeProgressListener, setCurrentProgress
public double getMinimumChange()
public void setMinimumChange(double minimumChange)
public void addProgressReporter(ProgressReporter reporter)
1
. If reporter already exists its
weight will be changed to 1
.reporter
- reporterpublic void addProgressReporter(ProgressReporter reporter, double weight)
reporter
with given weight
. If reporter already exists
its weight
and message
will be updated.reporter
- reporterweight
- weightpublic void addProgressReporter(ProgressReporter reporter, double weight, java.lang.String message)
reporter
with given weight
. If reporter already exists
its weight
and message
will be updated.reporter
- reporterweight
- weightmessage
- message that will be reported when this reporter send progress event. If
null
the original message send by reporter will be used.public void removeProgressReporter(ProgressReporter reporter)
public void removeAllProgressReporter()
public void progressNotification(ProgressEvent event)
ProgressListener
progressNotification
in interface ProgressListener
event
- event information.