Package org.apache.maven.api.cli.logging
Class AccumulatingLogger
java.lang.Object
org.apache.maven.api.cli.logging.AccumulatingLogger
- All Implemented Interfaces:
Logger
Early CLI
Logger
that simply accumulates log entries until some point a real logger can emit them. This
logger is created at start, and it exists while no logging is available yet.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.maven.api.cli.Logger
Logger.Entry, Logger.Level
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondrain()
If this is an accumulating log, it will "drain" this instance.void
log
(Logger.Level level, String message, Throwable error) Logs a message at the specified level with an associated exception.
-
Constructor Details
-
AccumulatingLogger
public AccumulatingLogger()
-
-
Method Details
-
log
Description copied from interface:Logger
Logs a message at the specified level with an associated exception. -
drain
Description copied from interface:Logger
If this is an accumulating log, it will "drain" this instance. It returns the accumulated log entries, and also "resets" this instance to empty (initial) state.
-