-- | Event type class. All events that can be applied to aggregate roots -- are required have an instance for this class. module Data.CQRS.Event ( Event(..) ) where -- | Event class for applying events to aggregates. class Event e a | e -> a where -- | Apply an event to the aggregate and return the updated aggregate. applyEvent :: e -> a -> a