Intersoft ClientUI Documentation
EventAggregator Class
Members  See Also  Send Feedback
Intersoft.Client.Framework Namespace : EventAggregator Class






Represents a class that serves as the hub/aggregator for events messaging.

Object Model

EventAggregator Class

Syntax

Visual Basic (Declaration) 
Public Class EventAggregator 
   Implements IEventAggregator 
Visual Basic (Usage)Copy Code
Dim instance As EventAggregator
C# 
public class EventAggregator : IEventAggregator  
Delphi 
public class EventAggregator = class(IEventAggregator)
JScript 
public class EventAggregator implements IEventAggregator 
Managed Extensions for C++ 
public __gc class EventAggregator : public IEventAggregator  
C++/CLI 
public ref class EventAggregator : public IEventAggregator  

Remarks

ClientUI’s event aggregator is designed to be simple and easy-to-use, yet powerful enough to cover a number of advanced scenarios. It takes only a single line of code to subscribe to an event, as well as for the event publication. See the following examples.

C# Copy Code
// Subscribe to an event
EventAggregator.Default.Subscribe<MailNotificationEvent, Mail>(OnMailReceived);

// Publish an event
EventAggregator.Default.Publish<MailNotificationEvent, Mail>(this.MailEntity);

To learn more about event aggregator concept and usage, see Event Aggregator Overview.

Event aggregator facilitates the decoupling of publisher and subscribers messaging between different part of applications. It channels events from multiple objects into a single object to simplify registration for clients.

Inheritance Hierarchy

System.Object
   Intersoft.Client.Framework.EventAggregator

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2012 All Rights Reserved.