public class DefaultJTaskStatusController extends java.lang.Object implements TaskStatusController, Observer
TaskStatusController.| Constructor and Description |
|---|
DefaultJTaskStatusController(javax.swing.JLabel titlelabel,
javax.swing.JLabel messagelabel,
javax.swing.JProgressBar progressBar) |
DefaultJTaskStatusController(TaskStatus taskStatus,
javax.swing.JLabel titlelabel,
javax.swing.JLabel messagelabel,
javax.swing.JProgressBar progressBar) |
DefaultJTaskStatusController(TaskStatus taskStatus,
javax.swing.JLabel titlelabel,
javax.swing.JLabel messagelabel,
javax.swing.JProgressBar progressBar,
javax.swing.JButton cancelRequestButton,
javax.swing.JButton removeTaskButton) |
| Modifier and Type | Method and Description |
|---|---|
void |
bind(TaskStatus taskStatus) |
void |
bind(TaskStatusManager taskStatusManager) |
boolean |
getShowCancelButton() |
boolean |
getShowRemoveTaskButton() |
SimpleTaskStatus |
getSimpleTaskStatus() |
TaskStatus |
getTaskStatus() |
void |
message(java.lang.String message) |
void |
setCurValue(long value) |
void |
setShowCancelButton(boolean showCancelButton) |
void |
setShowRemoveTaskButton(boolean showRemoveTaskButton) |
void |
setTitle(java.lang.String title) |
void |
setVisible(boolean visible) |
void |
update(Observable observable,
java.lang.Object notification)
Called whenever a
Observable object is changed and this
Observer has registered on it to receive notifications. |
public DefaultJTaskStatusController(TaskStatus taskStatus, javax.swing.JLabel titlelabel, javax.swing.JLabel messagelabel, javax.swing.JProgressBar progressBar, javax.swing.JButton cancelRequestButton, javax.swing.JButton removeTaskButton)
public DefaultJTaskStatusController(TaskStatus taskStatus, javax.swing.JLabel titlelabel, javax.swing.JLabel messagelabel, javax.swing.JProgressBar progressBar)
public DefaultJTaskStatusController(javax.swing.JLabel titlelabel,
javax.swing.JLabel messagelabel,
javax.swing.JProgressBar progressBar)
public void setVisible(boolean visible)
setVisible in interface TaskStatusControllerpublic boolean getShowCancelButton()
getShowCancelButton in interface TaskStatusControllerpublic void setShowCancelButton(boolean showCancelButton)
setShowCancelButton in interface TaskStatusControllerpublic boolean getShowRemoveTaskButton()
getShowRemoveTaskButton in interface TaskStatusControllerpublic void setShowRemoveTaskButton(boolean showRemoveTaskButton)
setShowRemoveTaskButton in interface TaskStatusControllerpublic void bind(TaskStatus taskStatus)
bind in interface TaskStatusControllerpublic void bind(TaskStatusManager taskStatusManager)
bind in interface TaskStatusControllerpublic void update(Observable observable, java.lang.Object notification)
ObserverObservable object is changed and this
Observer has registered on it to receive notifications.
Implementations of this method will be called for each simple notification or, if a complex notification is created, for each of the child notifications.
In the latter case, don't assume any ordering in the notification between
this Observer and other Observers listening to the same
Observable.
In a complex notification scenario, if you want to receive only the
complex notification and not each of the child notifications, just
implement the ComplexObserver and prepare this method
implementation to handle receiving DefaultComplexNotification instances
as well as direct notification objects.
public TaskStatus getTaskStatus()
getTaskStatus in interface TaskStatusControllerpublic SimpleTaskStatus getSimpleTaskStatus()
getSimpleTaskStatus in interface TaskStatusControllerpublic void setTitle(java.lang.String title)
setTitle in interface TaskStatusControllerpublic void message(java.lang.String message)
message in interface TaskStatusControllerpublic void setCurValue(long value)
setCurValue in interface TaskStatusController