public class ProgressListenerFactory
extends java.lang.Object
ProgressListeners
. If an instance of a ProgressListener is set,
this instance is returned instead of creating a new one. This allows calling applications to set their own
ProgressListener, while preserving backwards compatibility.Modifier and Type | Field and Description |
---|---|
private ProgressListener |
listener |
private static ProgressListenerFactory |
me |
Constructor and Description |
---|
ProgressListenerFactory() |
Modifier and Type | Method and Description |
---|---|
ProgressListener |
createProgressListener(int numIterations,
java.lang.String iteration) |
ProgressListener |
createProgressListener(int numIterations,
java.lang.String iteration,
int stepWidth) |
ProgressListener |
createProgressListener(int numIterations,
java.lang.String iteration,
int stepWidth,
int newLineWidth) |
static ProgressListenerFactory |
getInstance() |
ProgressListener |
getListener() |
void |
setListener(ProgressListener listener) |
private static ProgressListenerFactory me
private ProgressListener listener
public ProgressListener createProgressListener(int numIterations, java.lang.String iteration)
numIterations
- maxIterationspublic ProgressListener createProgressListener(int numIterations, java.lang.String iteration, int stepWidth)
public ProgressListener createProgressListener(int numIterations, java.lang.String iteration, int stepWidth, int newLineWidth)
public static ProgressListenerFactory getInstance()
public ProgressListener getListener()
public void setListener(ProgressListener listener)