Appccelerate.EventBroker.Matchers.NotAlreadyCanceled.Match C# (CSharp) Method

Match() public method

Returns whether the publication and subscription match and the event published by the publisher will be relayed to the subscriber.

Matches if the event arguments are CancelEventArgs that are not yet canceled.

public Match ( IPublication publication, ISubscription subscription, EventArgs e ) : bool
publication IPublication The publication.
subscription ISubscription The subscription.
e System.EventArgs The instance containing the event data.
return bool
        public bool Match(IPublication publication, ISubscription subscription, EventArgs e)
        {
            var cancelEventArgs = e as CancelEventArgs;
            return cancelEventArgs != null && !cancelEventArgs.Cancel;
        }
NotAlreadyCanceled