toxgene.util.ToXgeneReporterImpl 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!
/**
* Implements a simple reporting tool for the command line version of ToXgene
*
* @author Denilson Barbosa
*
* @version 0.1
*/
package toxgene.util;
import java.util.Vector;
import toxgene.interfaces.ToXgeneReporter;
public class ToXgeneReporterImpl implements ToXgeneReporter{
private boolean verbose;
private boolean showWarnings;
private Vector warnings;
public ToXgeneReporterImpl(boolean verbose, boolean showWarnings){
this.verbose = verbose;
this.showWarnings = showWarnings;
warnings = new Vector(10,10);
}
public void warning(String message){
warnings.add(message);
}
public void explain(String message){
if (verbose)
System.out.println(message);
}
public void progress(String message){
System.out.print(message);
}
public int warnings(){
return warnings.size();
}
public void printAllWarnings(){
if (showWarnings)
for (int i=0; i