Interface StatefulMessageLogger

All Superinterfaces:
MessageLogger
All Known Implementing Classes:
ConsoleMessageLogger, FailureOnlyMessageLogger, MultipleLoggers, StatefulNullMessageLogger, TextFileMessageLogger

public interface StatefulMessageLogger extends MessageLogger
A MessageLogger that can be started and stopped, and is aware of this state.
Author:
Owen Feehan
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    close(boolean successful, boolean warningOccurred)
    Stops logging.
    void
    Starts logging.

    Methods inherited from interface org.anchoranalysis.core.log.MessageLogger

    log, logEmptyLine, logFormatted
  • Method Details

    • start

      void start() throws OperationFailedException
      Starts logging.

      This must be called once before any logging occurs.

      Throws:
      OperationFailedException - if logging cannot be successfully started.
    • close

      void close(boolean successful, boolean warningOccurred)
      Stops logging.

      This must be called once after all logging has occurred.

      Parameters:
      successful - true when the task completed successfully.
      warningOccurred - true if at least one warning has occurred, false otherwise.