Search Results for

    Show / Hide Table of Contents

    Class WeakEventHandler

    A weak event handler factory

    Inheritance
    System.Object
    WeakEventHandler
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: OSGeo.MapGuide.MaestroAPI
    Assembly: OSGeo.MapGuide.MaestroAPI.dll
    Syntax
    public static class WeakEventHandler

    Methods

    | Improve this Doc View Source

    Match(Delegate, Delegate)

    Returns true if the given weak and strong event handlers match

    Declaration
    public static bool Match(Delegate weakEventHandler, Delegate strongEventHandler)
    Parameters
    Type Name Description
    System.Delegate weakEventHandler
    System.Delegate strongEventHandler
    Returns
    Type Description
    System.Boolean
    | Improve this Doc View Source

    Wrap(EventHandler, Action<EventHandler>)

    Wraps the given event handler as a weak event

    Declaration
    public static EventHandler Wrap(EventHandler eh, Action<EventHandler> cleanup)
    Parameters
    Type Name Description
    System.EventHandler eh
    System.Action<System.EventHandler> cleanup
    Returns
    Type Description
    System.EventHandler
    | Improve this Doc View Source

    Wrap<TEventHandler>(TEventHandler, Action<TEventHandler>)

    Wraps the given event handler as a weak event

    Declaration
    public static TEventHandler Wrap<TEventHandler>(TEventHandler eh, Action<TEventHandler> cleanup)
        where TEventHandler : class
    Parameters
    Type Name Description
    TEventHandler eh
    System.Action<TEventHandler> cleanup
    Returns
    Type Description
    TEventHandler
    Type Parameters
    Name Description
    TEventHandler
    | Improve this Doc View Source

    Wrap<TEventArgs>(EventHandler<TEventArgs>, Action<EventHandler<TEventArgs>>)

    Wraps the given event handler as a weak event

    Declaration
    public static EventHandler<TEventArgs> Wrap<TEventArgs>(EventHandler<TEventArgs> eh, Action<EventHandler<TEventArgs>> cleanup)
        where TEventArgs : EventArgs
    Parameters
    Type Name Description
    System.EventHandler<TEventArgs> eh
    System.Action<System.EventHandler<TEventArgs>> cleanup
    Returns
    Type Description
    System.EventHandler<TEventArgs>
    Type Parameters
    Name Description
    TEventArgs
    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright © 2009 - 2022 Jackie Ng