Method CreateDelegate
CreateDelegate<T>(MethodBase)
Creates a delegate of the specified type from this method.
public static T CreateDelegate<T>(this MethodBase method) where T : Delegate
Parameters
method
MethodBase- The method to create the delegate from.
Returns
- T
- The delegate for this method.
Type Parameters
T
- The type of the delegate to create.
CreateDelegate<T>(MethodBase, object?)
Creates a delegate of the specified type with the specified target from this method.
public static T CreateDelegate<T>(this MethodBase method, object? target) where T : Delegate
Parameters
method
MethodBase- The method to create the delegate from.
target
object- The object targeted by the delegate.
Returns
- T
- The delegate for this method.
Type Parameters
T
- The type of the delegate to create.
CreateDelegate(MethodBase, Type)
Creates a delegate of the specified type from this method.
public static Delegate CreateDelegate(this MethodBase method, Type delegateType)
Parameters
method
MethodBase- The method to create the delegate from.
delegateType
Type- The type of the delegate to create.
Returns
- Delegate
- The delegate for this method.
CreateDelegate(MethodBase, Type, object?)
Creates a delegate of the specified type with the specified target from this method.
public static Delegate CreateDelegate(this MethodBase method, Type delegateType, object? target)
Parameters
method
MethodBase- The method to create the delegate from.
delegateType
Type- The type of the delegate to create.
target
object- The object targeted by the delegate.
Returns
- Delegate
- The delegate for this method.