toxgene.interfaces.ToXgeneReporter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ToxGene Show documentation
Show all versions of ToxGene Show documentation
Modified ToXGene for the iBench project.
The newest version!
package toxgene.interfaces;
/**
* Interface for coupling ToXgene with a reporting tool that provides
* feedback during a data generation session. Three kinds of messages
* are sent:
*
* - warnings describe non-fatal exceptional conditions
* during the session (e.g., the result of a query in the template is
* empty);
* - progress report messages provide feedback on the
* completion of large tasks (e.g., generating a collection of
* documents);
* - explain messages provide feedback on how a template is
* processed (e.g., how a query expression is parsed).
*
* Note that fatal exceptional conditions are always reporter via
* ToXgeneErrorException
exceptions.
*
*@author Denilson Barbosa
*@version 0.1
*/
public interface ToXgeneReporter{
/**
* Receives a warning message about a non-fatal exceptional
* situation during the processing of the template. This message
* should be sever enough that the user may be interested in seeing it.
*
* @param message a warning message
*/
public void warning(String message);
/**
* Receives an explanatory message that helps understand how ToXgene
* processes the template. Most of these messages are produced
* during the parsing of the template and serve as "debugging"
* information. All these messages can be safely ignored.
*
* @param message an explanatory message
*/
public void explain(String message);
/**
* Receives a message indacting the progress of the processing of
* the template, such as notifications of the start/end of
* parsing. All these messages can be safely ignored.
*
* Some of the progress report messages are used to provide
* feedback on the completion of a task. This is done by printing
* "bakcspace" characters (i.e, '\b'
followed by the
* percentage of the completion of the task. A more elaborate
* progress indicator could be implemented by decoding these
* messages.
*
* @param message a progress report message
*/
public void progress(String message);
}