|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.dna.common.monitor.ProgressStatus
@Immutable public class ProgressStatus
A snapshot of the progress on an activity.
Constructor Summary | |
---|---|
ProgressStatus(java.lang.String activityName,
java.lang.String message,
double percentWorked,
boolean cancelled)
Create the progress status. |
|
ProgressStatus(java.lang.String activityName,
java.lang.String message,
double workedSoFar,
double totalWork,
boolean cancelled)
Create the progress status and compute the percentage worked. |
Method Summary | |
---|---|
int |
compareTo(ProgressStatus that)
|
boolean |
equals(java.lang.Object obj)
|
java.lang.String |
getActivityName()
Get the name of the activity. |
java.lang.String |
getMessage()
Get the progress monitor's text message. |
double |
getPercentWorked()
Get the progress as a percentage of the total work that's been completed. |
int |
hashCode()
|
boolean |
isCancelled()
Return whether the activity was requested to be cancelled. |
boolean |
isDone()
Return whether work on this activity has completed. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ProgressStatus(java.lang.String activityName, java.lang.String message, double percentWorked, boolean cancelled)
activityName
- the name of the activity, which may not be nullmessage
- the message for the progress, which may not be nullpercentWorked
- the percentage worked, ranging from 0.0 for not started to 100.0 for complete; a negative value are
treated as 0.0, while a value greater than 100.0 is treated as 100.0cancelled
- true if the activity has been requested to be cancelled, or false otherwisepublic ProgressStatus(java.lang.String activityName, java.lang.String message, double workedSoFar, double totalWork, boolean cancelled)
activityName
- the name of the activity, which may not be nullmessage
- the message for the progress, which may not be nullworkedSoFar
- the amount of work so far percentage workedtotalWork
- the total amount of work for this activitycancelled
- true if the activity has been requested to be cancelled, or false otherwiseMethod Detail |
---|
public java.lang.String getActivityName()
public double getPercentWorked()
public java.lang.String getMessage()
public boolean isDone()
isCancelled()
public boolean isCancelled()
isDone()
public java.lang.String toString()
toString
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int compareTo(ProgressStatus that)
compareTo
in interface java.lang.Comparable<ProgressStatus>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |