Class LoggingDomainEventSubscriber
java.lang.Object
com.reallifedeveloper.common.domain.event.LoggingDomainEventSubscriber
- All Implemented Interfaces:
DomainEventSubscriber<DomainEvent>
public class LoggingDomainEventSubscriber
extends Object
implements DomainEventSubscriber<DomainEvent>
A
DomainEventSubscriber
that logs all events using Slf4j.- Author:
- RealLifeDeveloper
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionClass
<? extends DomainEvent> Gives the type of domain event to handle.void
handleEvent
(DomainEvent event) Handles the given event.
-
Constructor Details
-
LoggingDomainEventSubscriber
public LoggingDomainEventSubscriber()
-
-
Method Details
-
handleEvent
Description copied from interface:DomainEventSubscriber
Handles the given event.- Specified by:
handleEvent
in interfaceDomainEventSubscriber<DomainEvent>
- Parameters:
event
- the domain event to handle
-
eventType
Description copied from interface:DomainEventSubscriber
Gives the type of domain event to handle.- Specified by:
eventType
in interfaceDomainEventSubscriber<DomainEvent>
- Returns:
- the type of domain event to handle
-