C# Класс Spring.Objects.Events.Support.EventManipulationUtils

Utility class to aid in the manipulation of events and delegates.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
GetHandlerDelegate ( Type delegateType, object targetSubscriber, MethodInfo targetSubscriberDelegateMethod ) : Delegate

Returns a new instance of the requested Delegate.

Often used to wire subscribers to event publishers.

GetMethodInfoMatchingSignature ( MethodInfo invoke, Type subscriberType ) : MethodInfo

Queries the input type for a MethodInfo signature matching the input MethodInfo signature.

Typically used to query a potential subscriber to see if they implement an event handler.

Приватные методы

Метод Описание
EventManipulationUtils ( ) : System

Creates a new instance of the EventManipulationUtilities class.

This is a utility class, and as such has no publicly visible constructors.

Описание методов

GetHandlerDelegate() публичный статический Метод

Returns a new instance of the requested Delegate.

Often used to wire subscribers to event publishers.

public static GetHandlerDelegate ( Type delegateType, object targetSubscriber, MethodInfo targetSubscriberDelegateMethod ) : Delegate
delegateType System.Type /// The of delegate to create. ///
targetSubscriber object /// The target subscriber object that contains the delegate implementation. ///
targetSubscriberDelegateMethod System.Reflection.MethodInfo /// referencing the delegate method on the subscriber. ///
Результат System.Delegate

GetMethodInfoMatchingSignature() публичный статический Метод

Queries the input type for a MethodInfo signature matching the input MethodInfo signature.
Typically used to query a potential subscriber to see if they implement an event handler.
public static GetMethodInfoMatchingSignature ( MethodInfo invoke, Type subscriberType ) : MethodInfo
invoke System.Reflection.MethodInfo to match against
subscriberType System.Type to query
Результат System.Reflection.MethodInfo