Search Results for

    Show / Hide Table of Contents
    View Source

    Class QueuingEventDispatcherBase

    An IEventDispatcher that queues events.

    Inheritance
    object
    Namespace: Umbraco.Cms.Core.Events
    Assembly: Umbraco.Core.dll
    Syntax
    public abstract class QueuingEventDispatcherBase : IEventDispatcher
    Remarks

    Can raise, or ignore, cancelable events, depending on option.

    Implementations must override ScopeExitCompleted to define what to do with the events when the scope exits and has been completed.

    If the scope exits without being completed, events are ignored.

    Constructors

    View Source

    QueuingEventDispatcherBase(bool)

    Declaration
    protected QueuingEventDispatcherBase(bool raiseCancelable)
    Parameters
    Type Name Description
    bool raiseCancelable

    Methods

    View Source

    Dispatch(EventHandler, object, EventArgs, string?)

    Dispatches an event.

    Declaration
    public void Dispatch(EventHandler eventHandler, object sender, EventArgs args, string? eventName = null)
    Parameters
    Type Name Description
    EventHandler eventHandler

    The event handler.

    object sender

    The object that raised the event.

    EventArgs args

    The event data.

    string eventName
    Remarks

    See general remarks on the interface.

    View Source

    DispatchCancelable(EventHandler, object, CancellableEventArgs, string?)

    Dispatches a cancelable event.

    Declaration
    public bool DispatchCancelable(EventHandler eventHandler, object sender, CancellableEventArgs args, string? eventName = null)
    Parameters
    Type Name Description
    EventHandler eventHandler

    The event handler.

    object sender

    The object that raised the event.

    CancellableEventArgs args

    The event data.

    string eventName
    Returns
    Type Description
    bool

    A value indicating whether the cancelable event was cancelled.

    Remarks

    See general remarks on the interface.

    View Source

    DispatchCancelable<TArgs>(EventHandler<TArgs>, object, TArgs, string?)

    Dispatches a cancelable event.

    Declaration
    public bool DispatchCancelable<TArgs>(EventHandler<TArgs> eventHandler, object sender, TArgs args, string? eventName = null) where TArgs : CancellableEventArgs
    Parameters
    Type Name Description
    EventHandler<TArgs> eventHandler

    The event handler.

    object sender

    The object that raised the event.

    TArgs args

    The event data.

    string eventName
    Returns
    Type Description
    bool

    A value indicating whether the cancelable event was cancelled.

    Type Parameters
    Name Description
    TArgs
    Remarks

    See general remarks on the interface.

    View Source

    DispatchCancelable<TSender, TArgs>(TypedEventHandler<TSender, TArgs>, TSender, TArgs, string?)

    Dispatches a cancelable event.

    Declaration
    public bool DispatchCancelable<TSender, TArgs>(TypedEventHandler<TSender, TArgs> eventHandler, TSender sender, TArgs args, string? eventName = null) where TArgs : CancellableEventArgs
    Parameters
    Type Name Description
    TypedEventHandler<TSender, TArgs> eventHandler

    The event handler.

    TSender sender

    The object that raised the event.

    TArgs args

    The event data.

    string eventName
    Returns
    Type Description
    bool

    A value indicating whether the cancelable event was cancelled.

    Type Parameters
    Name Description
    TSender
    TArgs
    Remarks

    See general remarks on the interface.

    View Source

    Dispatch<TArgs>(EventHandler<TArgs>, object, TArgs, string?)

    Dispatches an event.

    Declaration
    public void Dispatch<TArgs>(EventHandler<TArgs> eventHandler, object sender, TArgs args, string? eventName = null)
    Parameters
    Type Name Description
    EventHandler<TArgs> eventHandler

    The event handler.

    object sender

    The object that raised the event.

    TArgs args

    The event data.

    string eventName
    Type Parameters
    Name Description
    TArgs
    Remarks

    See general remarks on the interface.

    View Source

    Dispatch<TSender, TArgs>(TypedEventHandler<TSender, TArgs>, TSender, TArgs, string?)

    Dispatches an event.

    Declaration
    public void Dispatch<TSender, TArgs>(TypedEventHandler<TSender, TArgs> eventHandler, TSender sender, TArgs args, string? eventName = null)
    Parameters
    Type Name Description
    TypedEventHandler<TSender, TArgs> eventHandler

    The event handler.

    TSender sender

    The object that raised the event.

    TArgs args

    The event data.

    string eventName
    Type Parameters
    Name Description
    TSender
    TArgs
    Remarks

    See general remarks on the interface.

    View Source

    GetEvents(EventDefinitionFilter)

    Gets the collected events.

    Declaration
    public IEnumerable<IEventDefinition> GetEvents(EventDefinitionFilter filter)
    Parameters
    Type Name Description
    EventDefinitionFilter filter
    Returns
    Type Description
    IEnumerable<IEventDefinition>

    The collected events.

    View Source

    ScopeExit(bool)

    Notifies the dispatcher that the scope is exiting.

    Declaration
    public void ScopeExit(bool completed)
    Parameters
    Type Name Description
    bool completed

    A value indicating whether the scope completed.

    View Source

    ScopeExitCompleted()

    Declaration
    protected abstract void ScopeExitCompleted()
    • Edit this page
    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX