public class IterationStartReporter extends AbstractIterativeAlgorithmListener
IterativeAlgorithm,
Serialized Form| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
DEFAULT_FORMAT
The default format is "Iteration %d".
|
protected java.lang.String |
format
The format for the performance report, passed to String.format.
|
protected java.io.PrintStream |
out
The print stream to report performance to.
|
| Constructor and Description |
|---|
IterationStartReporter()
Creates a new
IterationStartReporter that
reports to System.out using the default format. |
IterationStartReporter(java.io.PrintStream out)
Creates a new
IterationStartReporter that
reports to the given print stream using the default format. |
IterationStartReporter(java.io.PrintStream out,
java.lang.String format)
Creates a new
IterationStartReporter that
reports to the given print stream and format. |
IterationStartReporter(java.lang.String format)
Creates a new
IterationStartReporter that
reports to System.out and the given format. |
| Modifier and Type | Method and Description |
|---|---|
void |
stepStarted(IterativeAlgorithm algorithm)
This method is called when the algorithm has started a step in its
execution.
|
algorithmEnded, algorithmStarted, stepEndedclonepublic static final java.lang.String DEFAULT_FORMAT
protected java.io.PrintStream out
protected java.lang.String format
public IterationStartReporter()
IterationStartReporter that
reports to System.out using the default format.public IterationStartReporter(java.io.PrintStream out)
IterationStartReporter that
reports to the given print stream using the default format.out - Print stream to report the status to.public IterationStartReporter(java.lang.String format)
IterationStartReporter that
reports to System.out and the given format.format - Format string for the status messages, which passed to
String.format.public IterationStartReporter(java.io.PrintStream out,
java.lang.String format)
IterationStartReporter that
reports to the given print stream and format.out - Print stream to report the status to.format - Format string for the status messages, which passed to
String.format.public void stepStarted(IterativeAlgorithm algorithm)
IterativeAlgorithmListenerstepStarted in interface IterativeAlgorithmListenerstepStarted in class AbstractIterativeAlgorithmListeneralgorithm - The algorithm that has started another step of its execution.