Package de.intarsys.tools.reporter
Class ReplayReporter
- java.lang.Object
-
- de.intarsys.tools.reporter.ReplayReporter
-
- All Implemented Interfaces:
IReporter,IReporterSupport
public class ReplayReporter extends java.lang.Object implements IReporter, IReporterSupport
AnIReporterthat may be used to intercept the reporting information and "replay" them later on on anotherIReporterinstance.This is useful if an object receiving reporting information may be dynamically multiplexed on many reporting events emitting instances, for example a window showing a currently active object.
-
-
Field Summary
-
Fields inherited from interface de.intarsys.tools.reporter.IReporter
STYLE_BEEP, STYLE_NONE, STYLE_STANDALONE
-
-
Constructor Summary
Constructors Constructor Description ReplayReporter(java.lang.Object owner)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddMessage(ReportMessage message)voidaddReporter(IReporter reporter)java.lang.ObjectgetOwner()voidremoveReporter(IReporter reporter)protected voidreplay(IReporter reporter)voidreportActivityEnd()Indicate the end of an activity.voidreportActivityStart(java.lang.String activity, int style)Indicate the beginning of an activity, possibly blocking system interaction.voidreportError(java.lang.String title, java.lang.String message, java.lang.Throwable t, int style)Indicate an error condition.voidreportMessage(java.lang.String title, java.lang.String message, int style)Report a message to the user.voidreportProgress(java.lang.String message, int percent, int style)Indicate the progress of an ongoing activity.voidreportStatus(java.lang.String message, int style)Report a simple state information.
-
-
-
Method Detail
-
addMessage
protected void addMessage(ReportMessage message)
-
addReporter
public void addReporter(IReporter reporter)
- Specified by:
addReporterin interfaceIReporterSupport
-
getOwner
public java.lang.Object getOwner()
-
removeReporter
public void removeReporter(IReporter reporter)
- Specified by:
removeReporterin interfaceIReporterSupport
-
replay
protected void replay(IReporter reporter)
-
reportActivityEnd
public void reportActivityEnd()
Description copied from interface:IReporterIndicate the end of an activity.- Specified by:
reportActivityEndin interfaceIReporter
-
reportActivityStart
public void reportActivityStart(java.lang.String activity, int style)Description copied from interface:IReporterIndicate the beginning of an activity, possibly blocking system interaction.- Specified by:
reportActivityStartin interfaceIReporter- Parameters:
activity- A label for reporting the activity.
-
reportError
public void reportError(java.lang.String title, java.lang.String message, java.lang.Throwable t, int style)Description copied from interface:IReporterIndicate an error condition. This method will return normally after a possible user interaction, any error handling is still up to the caller.- Specified by:
reportErrorin interfaceIReporter
-
reportMessage
public void reportMessage(java.lang.String title, java.lang.String message, int style)Description copied from interface:IReporterReport a message to the user. The message should be displayed in a blocking way in an interactive system.- Specified by:
reportMessagein interfaceIReporter
-
reportProgress
public void reportProgress(java.lang.String message, int percent, int style)Description copied from interface:IReporterIndicate the progress of an ongoing activity. The activity will probably run concurrently.- Specified by:
reportProgressin interfaceIReporter
-
reportStatus
public void reportStatus(java.lang.String message, int style)Description copied from interface:IReporterReport a simple state information. This should not block the system in any way.- Specified by:
reportStatusin interfaceIReporter
-
-