|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.wiki.ui.progress.ProgressManager
public class ProgressManager
Manages progressing items. In general this class is used whenever JSPWiki is doing something which may require a long time. In addition, this manager provides a JSON interface for finding remotely what the progress is. The JSON object name is JSON_PROGRESSTRACKER = ""progressTracker"".
Nested Class Summary | |
---|---|
class |
ProgressManager.JSONTracker
Provides access to a progress indicator, assuming you know the ID. |
Field Summary | |
---|---|
static String |
JSON_PROGRESSTRACKER
The name of the progress tracker JSON object. |
Constructor Summary | |
---|---|
ProgressManager()
Creates a new ProgressManager. |
Method Summary | |
---|---|
String |
getNewProgressIdentifier()
You can use this to get an unique process identifier. |
int |
getProgress(String id)
Get the progress in percents. |
void |
startProgress(ProgressItem pi,
String id)
Call this method to get your ProgressItem into the ProgressManager queue. |
void |
stopProgress(String id)
Call this method to remove your ProgressItem from the queue (after which getProgress() will no longer find it. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String JSON_PROGRESSTRACKER
Constructor Detail |
---|
public ProgressManager()
Method Detail |
---|
public String getNewProgressIdentifier()
public void startProgress(ProgressItem pi, String id)
pi
- ProgressItem to startid
- The progress identifierpublic void stopProgress(String id)
id
- The progress identifierpublic int getProgress(String id) throws IllegalArgumentException
id
- The progress identifier.
IllegalArgumentException
- If no such progress item exists.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |