Package net.ssehub.easy.basics.progress
Class BasicProgressObserver.Task
java.lang.Object
net.ssehub.easy.basics.progress.BasicProgressObserver.Task
- All Implemented Interfaces:
ProgressObserver.ISubtask,ProgressObserver.ITask
- Enclosing class:
BasicProgressObserver
private static class BasicProgressObserver.Task
extends Object
implements ProgressObserver.ITask, ProgressObserver.ISubtask
Representation of a task, which will be observed by the
BasicProgressObserver.IProgressMonitor.- Author:
- Holger Eichelberger
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetName()Getter for the name.intsetCurrent(int current) Sets the current progress of the current task.voidsetMax(int max) Setter for the maximum of the task.
-
Field Details
-
name
-
max
private int max -
current
private int current
-
-
Constructor Details
-
Task
Sole constructor of this class.- Parameters:
name- The name of the task which should be created.
-
-
Method Details
-
getName
Getter for the name.- Returns:
- The name of this task.
-
setMax
public void setMax(int max) Setter for the maximum of the task.- Parameters:
max- An integer value greater than 0.
-
setCurrent
public int setCurrent(int current) Sets the current progress of the current task.- Parameters:
current- The number of already completed steps.- Returns:
- How many steps are still open to fulfill the current task.
-