S - The concrete type of the state object.public class DefaultLogger<S extends State> extends Object implements CombinedLogger<S>
| Constructor and Description |
|---|
DefaultLogger() |
| Modifier and Type | Method and Description |
|---|---|
void |
onCommandHandlerError(Throwable error,
Command command,
Collection<Event> events)
Called when an error occurs during the handling of a command.
|
void |
onCommandHandlerResult(Command command,
Collection<Event> events)
Called when a command handler returns a result.
|
void |
onEventHandlerError(Throwable error,
Event event,
S newState)
Called when an error occurs during the handling of an event.
|
void |
onEventHandlerResult(Event event,
S newState)
Called when an event handler returns a result.
|
public void onCommandHandlerError(Throwable error, Command command, Collection<Event> events)
CommandLoggeronCommandHandlerError in interface CommandLoggererror - The error that occurred.command - The command that was handled.events - The resulting event(s). Note: command handlers are not required to produce
events.public void onCommandHandlerResult(Command command, Collection<Event> events)
CommandLoggeronCommandHandlerResult in interface CommandLoggercommand - The command that was handled.events - The resulting event(s). Note: command handlers are not required to produce
events.public void onEventHandlerError(Throwable error, Event event, S newState)
EventLoggeronEventHandlerError in interface EventLogger<S extends State>error - The error that occurred.event - The event that was handled.newState - The new state that was returned by the event handler.public void onEventHandlerResult(Event event, S newState)
EventLoggeronEventHandlerResult in interface EventLogger<S extends State>event - The event that was handled.newState - The new state that was returned by the event handler.Copyright © 2016 Cooking Fox. All rights reserved.