public class ObservableTask
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private int |
count |
private ProgressObserver |
observer |
private ProgressObserver.ISubtask |
subtask |
private ProgressObserver.ITask |
task |
| Constructor and Description |
|---|
ObservableTask(java.lang.String name,
int max,
ObservableTask parent)
Creates a new observable sub task.
|
ObservableTask(java.lang.String name,
int max,
ProgressObserver observer)
Creates a new observable top-level task.
|
ObservableTask(java.lang.String name,
int max,
ProgressObserver observer,
ProgressObserver.ITask task)
Creates a new observable (sub) task.
|
| Modifier and Type | Method and Description |
|---|---|
void |
notifyEnd()
Notifies the observer about ending this (sub)task.
|
void |
notifyProgress()
Notifies the observer about progressing on step.
|
void |
notifyProgress(int steps)
Notifies the observer about progressing multiple steps.
|
private ProgressObserver.ITask task
private ProgressObserver.ISubtask subtask
private ProgressObserver observer
private int count
public ObservableTask(java.lang.String name,
int max,
ProgressObserver observer)
name - the name of the taskmax - the maximum stepsobserver - the observerpublic ObservableTask(java.lang.String name,
int max,
ProgressObserver observer,
ProgressObserver.ITask task)
name - the name of the taskmax - the maximum stepsobserver - the observertask - the parent task (may be null)public ObservableTask(java.lang.String name,
int max,
ObservableTask parent)
name - the name of the sub taskmax - the maximum stepsparent - The parent taskpublic void notifyProgress()
public void notifyProgress(int steps)
steps - the progressed stepspublic void notifyEnd()
Copyright © 2009 - 2018 SSE. All Rights Reserved.