/V1/trunk/Source/CAL/Composite/Events/IEventSubscription.cs
C# | 40 lines | 10 code | 3 blank | 27 comment | 0 complexity | db5f9454f74377dc08a0478159d5c9ee MD5 | raw file
- //===============================================================================
- // Microsoft patterns & practices
- // Composite Application Guidance for Windows Presentation Foundation
- //===============================================================================
- // Copyright (c) Microsoft Corporation. All rights reserved.
- // THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY
- // OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT
- // LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
- // FITNESS FOR A PARTICULAR PURPOSE.
- //===============================================================================
- // The example companies, organizations, products, domain names,
- // e-mail addresses, logos, people, places, and events depicted
- // herein are fictitious. No association with any real company,
- // organization, product, domain name, email address, logo, person,
- // places, or events is intended or should be inferred.
- //===============================================================================
-
- using System;
-
- namespace Microsoft.Practices.Composite.Events
- {
- ///<summary>
- /// Defines a contract for an event subscription to be used by <see cref="EventBase"/>.
- ///</summary>
- public interface IEventSubscription
- {
- /// <summary>
- /// Gets or sets a <see cref="Microsoft.Practices.Composite.Events.SubscriptionToken"/> that identifies this <see cref="IEventSubscription"/>.
- /// </summary>
- /// <value>A token that identifies this <see cref="IEventSubscription"/>.</value>
- SubscriptionToken SubscriptionToken { get; set; }
-
- /// <summary>
- /// Gets the execution strategy to publish this event.
- /// </summary>
- /// <returns>An <see cref="Action{T}"/> with the execution strategy, or <see langword="null" /> if the <see cref="IEventSubscription"/> is no longer valid.</returns>
- [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")]
- Action<object[]> GetExecutionStrategy();
- }
- }