namespace Caliburn.Micro.Core { using System; /// /// Enables loosely-coupled publication of and subscription to events. /// public interface IEventAggregator { /// /// Searches the subscribed handlers to check if we have a handler for /// the message type supplied. /// /// The message type to check with /// True if any handler is found, false if not. bool HandlerExistsFor(Type messageType); /// /// Subscribes an instance to all events declared through implementations of /// /// The instance to subscribe for event publication. void Subscribe(object subscriber); /// /// Unsubscribes the instance from all events. /// /// The instance to unsubscribe. void Unsubscribe(object subscriber); /// /// Publishes a message. /// /// The message instance. /// Allows the publisher to provide a custom thread marshaller for the message publication. void Publish(object message, Action marshal); } }