Interface Reporter
-
- All Known Subinterfaces:
GenerationReporter
,InterleavingGenerationReporter
- All Known Implementing Classes:
EmptyInterleavingGenerationReporter
,EmptySequentialGenerationReporter
,InterleavingExecutionReporterToGenerationReporterAdapter
,SequentialExecutionReporterToGenerationReporterAdapter
public interface Reporter
An interface defining a reporter which can be called by internal algorithms to notify the user of events not covered by an life cycle method in theGenerationReporter
. many default methods are just used to give the user a better callable interface and should not be implemented by an extending class.
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description static Reporter
getEmptyReporter()
void
report(ReportLevel level, Report report)
Reports the givenReport
at the specified level.void
report(ReportLevel level, Supplier<Report> reportSupplier)
This method has the same intentions asreport(ReportLevel, Report)
, but a supplier is given.default void
reportAssumptionSatisfaction(String assumptionKey)
Reports a violated assumption that occurred during algorithm execution.default void
reportAssumptionViolation(String assumptionKey)
Reports a violated assumption that occurred during algorithm execution.default void
reportDebug(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.DEBUG
and the given report.default void
reportDebug(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.DEBUG
and the given supplier.default void
reportError(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.ERROR
and the given report.default void
reportError(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.ERROR
and the given supplier.default void
reportFatal(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.FATAL
and the given report.default void
reportFatal(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.FATAL
and the given supplier.default void
reportInfo(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.INFO
and the given report.default void
reportInfo(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.INFO
and the given supplier.default void
reportTrace(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.TRACE
and the given report.default void
reportTrace(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.TRACE
and the given supplier.default void
reportWarn(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.WARN
and the given report.default void
reportWarn(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.WARN
and the given supplier.
-
-
-
Method Detail
-
reportTrace
default void reportTrace(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.TRACE
and the given report.- Parameters:
report
- what should be reported at levelReportLevel.TRACE
-
reportTrace
default void reportTrace(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.TRACE
and the given supplier.- Parameters:
reportSupplier
- what should be reported if the reporter listens at levelReportLevel.TRACE
-
reportDebug
default void reportDebug(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.DEBUG
and the given report.- Parameters:
report
- what should be reported at levelReportLevel.DEBUG
-
reportDebug
default void reportDebug(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.DEBUG
and the given supplier.- Parameters:
reportSupplier
- what should be reported if the reporter listens at levelReportLevel.DEBUG
-
reportInfo
default void reportInfo(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.INFO
and the given report.- Parameters:
report
- what should be reported at levelReportLevel.INFO
-
reportInfo
default void reportInfo(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.INFO
and the given supplier.- Parameters:
reportSupplier
- what should be reported if the reporter listens at levelReportLevel.INFO
-
reportWarn
default void reportWarn(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.WARN
and the given report.- Parameters:
report
- what should be reported at levelReportLevel.WARN
-
reportWarn
default void reportWarn(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.WARN
and the given supplier.- Parameters:
reportSupplier
- what should be reported if the reporter listens at levelReportLevel.WARN
-
reportError
default void reportError(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.ERROR
and the given report.- Parameters:
report
- what should be reported at levelReportLevel.ERROR
-
reportError
default void reportError(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.ERROR
and the given supplier.- Parameters:
reportSupplier
- what should be reported if the reporter listens at levelReportLevel.ERROR
-
reportFatal
default void reportFatal(Report report)
Callsreport(ReportLevel, Report)
with the levelReportLevel.FATAL
and the given report.- Parameters:
report
- what should be reported at levelReportLevel.FATAL
-
reportFatal
default void reportFatal(Supplier<Report> reportSupplier)
Callsreport(ReportLevel, Supplier)
with the levelReportLevel.FATAL
and the given supplier.- Parameters:
reportSupplier
- what should be reported if the reporter listens at levelReportLevel.FATAL
-
report
void report(ReportLevel level, Report report)
Reports the givenReport
at the specified level. The levels are used so that anyReporter
may filter information it wishes to receive.- Parameters:
level
- the of the report. Must not benull
report
- the report itself. Must not benull
-
report
void report(ReportLevel level, Supplier<Report> reportSupplier)
This method has the same intentions asreport(ReportLevel, Report)
, but a supplier is given. If any big calculations need to be performed for aReport
generation this method can be used to guarantee lazy de.rwth.swc.coffee4j.evaluation only if aReporter
is really interested in the report of the given level.- Parameters:
level
- the of the report. Must not benull
reportSupplier
- a supplier which can compute the real report. It and the returnedReport
must not benull
-
reportAssumptionViolation
default void reportAssumptionViolation(String assumptionKey)
Reports a violated assumption that occurred during algorithm execution. Does nothing by default.- Parameters:
assumptionKey
- the key for this assumption
-
reportAssumptionSatisfaction
default void reportAssumptionSatisfaction(String assumptionKey)
Reports a violated assumption that occurred during algorithm execution. Does nothing by default.- Parameters:
assumptionKey
- the key for this assumption
-
getEmptyReporter
static Reporter getEmptyReporter()
-
-