org.javasimon.javaee.reqreporter.StandardRequestReporter Maven / Gradle / Ivy
package org.javasimon.javaee.reqreporter;
/**
* Reports request to standard output (instead of Manager's message method) and omits less specific Simons from
* output (for instance JDBC's next).
*
* @author Richard "Virgo" Richter
*/
@SuppressWarnings("UnusedDeclaration")
public class StandardRequestReporter extends DefaultRequestReporter {
@Override
protected void reportMessage(String message) {
System.out.println(message);
}
@Override
protected boolean shouldBeAddedStopwatchInfo(StopwatchInfo info) {
return !(isJdbcResultSetNextSimon(info));
}
private boolean isJdbcResultSetNextSimon(StopwatchInfo info) {
return info.stopwatch.getName().contains(".sql.") && info.stopwatch.getName().endsWith(".next");
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy