Interface Reporter
-
- All Known Subinterfaces:
GenerationReporter,InterleavingGenerationReporter
- All Known Implementing Classes:
EmptyInterleavingGenerationReporter,EmptySequentialGenerationReporter,InterleavingExecutionReporterToGenerationReporterAdapter,SequentialExecutionReporterToGenerationReporterAdapter
public interface ReporterAn 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 ReportergetEmptyReporter()voidreport(ReportLevel level, Report report)Reports the givenReportat the specified level.voidreport(ReportLevel level, Supplier<Report> reportSupplier)This method has the same intentions asreport(ReportLevel, Report), but a supplier is given.default voidreportAssumptionSatisfaction(String assumptionKey)Reports a violated assumption that occurred during algorithm execution.default voidreportAssumptionViolation(String assumptionKey)Reports a violated assumption that occurred during algorithm execution.default voidreportDebug(Report report)Callsreport(ReportLevel, Report)with the levelReportLevel.DEBUGand the given report.default voidreportDebug(Supplier<Report> reportSupplier)Callsreport(ReportLevel, Supplier)with the levelReportLevel.DEBUGand the given supplier.default voidreportError(Report report)Callsreport(ReportLevel, Report)with the levelReportLevel.ERRORand the given report.default voidreportError(Supplier<Report> reportSupplier)Callsreport(ReportLevel, Supplier)with the levelReportLevel.ERRORand the given supplier.default voidreportFatal(Report report)Callsreport(ReportLevel, Report)with the levelReportLevel.FATALand the given report.default voidreportFatal(Supplier<Report> reportSupplier)Callsreport(ReportLevel, Supplier)with the levelReportLevel.FATALand the given supplier.default voidreportInfo(Report report)Callsreport(ReportLevel, Report)with the levelReportLevel.INFOand the given report.default voidreportInfo(Supplier<Report> reportSupplier)Callsreport(ReportLevel, Supplier)with the levelReportLevel.INFOand the given supplier.default voidreportTrace(Report report)Callsreport(ReportLevel, Report)with the levelReportLevel.TRACEand the given report.default voidreportTrace(Supplier<Report> reportSupplier)Callsreport(ReportLevel, Supplier)with the levelReportLevel.TRACEand the given supplier.default voidreportWarn(Report report)Callsreport(ReportLevel, Report)with the levelReportLevel.WARNand the given report.default voidreportWarn(Supplier<Report> reportSupplier)Callsreport(ReportLevel, Supplier)with the levelReportLevel.WARNand the given supplier.
-
-
-
Method Detail
-
reportTrace
default void reportTrace(Report report)
Callsreport(ReportLevel, Report)with the levelReportLevel.TRACEand 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.TRACEand 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.DEBUGand 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.DEBUGand 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.INFOand 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.INFOand 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.WARNand 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.WARNand 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.ERRORand 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.ERRORand 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.FATALand 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.FATALand 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 givenReportat the specified level. The levels are used so that anyReportermay filter information it wishes to receive.- Parameters:
level- the of the report. Must not benullreport- 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 aReportgeneration this method can be used to guarantee lazy de.rwth.swc.coffee4j.evaluation only if aReporteris really interested in the report of the given level.- Parameters:
level- the of the report. Must not benullreportSupplier- a supplier which can compute the real report. It and the returnedReportmust 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()
-
-