public class ProgressManager extends Object
Modifier and Type | Class and Description |
---|---|
class |
ProgressManager.JSONTracker
Provides access to a progress indicator, assuming you know the ID.
|
Modifier and Type | Field and Description |
---|---|
static String |
JSON_PROGRESSTRACKER
The name of the progress tracker JSON object.
|
Constructor and Description |
---|
ProgressManager()
Creates a new ProgressManager.
|
Modifier and Type | Method and Description |
---|---|
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.
|
public static final String JSON_PROGRESSTRACKER
public ProgressManager()
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.Copyright © 2001-2016 The Apache Software Foundation. All rights reserved.