Show / Hide Table of Contents

Class ExtensionRegistry

Represents registry of extension methods that can be registered for the specified type and be available using strongly typed reflection via Type<T>.

Inheritance
Object
ExtensionRegistry
Namespace: DotNext.Reflection
Assembly: DotNext.Reflection.dll
Syntax
public sealed class ExtensionRegistry : ConcurrentBag<MethodInfo>

Methods

| Improve this Doc View Source

RegisterInstance(MethodInfo)

Registers extension method as instance method which will be included into strongly typed reflection lookup performed by Get<D>(String, MethodLookup, Boolean) and related methods.

Declaration
public static void RegisterInstance(MethodInfo method)
Parameters
Type Name Description
MethodInfo method

Static method to register. Cannot be null.

| Improve this Doc View Source

RegisterInstance<D>(D)

Registers extension method which will be included into strongly typed reflection lookup performed by Unreflect<D>(MethodInfo) or Get<D>(String, MethodLookup, Boolean) methods.

Declaration
public static void RegisterInstance<D>(D delegate)

    where D : Delegate
Parameters
Type Name Description
D delegate

The delegate instance representing extension method.

Type Parameters
Name Description
D

The type of the delegate.

| Improve this Doc View Source

RegisterStatic<T>(MethodInfo)

Registers static method for the specified type in ad-hoc manner so it will be available using Get<D>(String, MethodLookup, Boolean) and related methods.

Declaration
public static void RegisterStatic<T>(MethodInfo method)
Parameters
Type Name Description
MethodInfo method

The static method implementation.

Type Parameters
Name Description
T

The type to be extended with static method.

| Improve this Doc View Source

RegisterStatic<T, D>(D)

Registers static method for the specified type in ad-hoc manner so it will be available using Get<D>(String, MethodLookup, Boolean) and related methods.

Declaration
public static void RegisterStatic<T, D>(D delegate)

    where D : Delegate
Parameters
Type Name Description
D delegate

The delegate instance representing extension method.

Type Parameters
Name Description
T

The type to be extended with static method.

D

The type of the delegate.

Extension Methods

AsyncLockAcquisition.AcquireLockAsync<T>(T, TimeSpan)
AsyncLockAcquisition.AcquireLockAsync<T>(T, CancellationToken)
AsyncLockAcquisition.AcquireReadLockAsync<T>(T, TimeSpan)
AsyncLockAcquisition.AcquireReadLockAsync<T>(T, CancellationToken)
AsyncLockAcquisition.AcquireWriteLockAsync<T>(T, TimeSpan)
AsyncLockAcquisition.AcquireWriteLockAsync<T>(T, CancellationToken)
AsyncLockAcquisition.AcquireUpgradeableReadLockAsync<T>(T, TimeSpan)
AsyncLockAcquisition.AcquireUpgradeableReadLockAsync<T>(T, CancellationToken)
ExpressionBuilder.Const<T>(T)
ObjectExtensions.GetUserData<T>(T)
ObjectExtensions.IsOneOf<T>(T, IEnumerable<T>)
ObjectExtensions.IsOneOf<T>(T, T[])
ObjectExtensions.Decompose<T, R1, R2>(T, Func<T, R1>, Func<T, R2>, out R1, out R2)
ObjectExtensions.Decompose<T, R1, R2>(T, ValueFunc<T, R1>, ValueFunc<T, R2>, out R1, out R2)
ObjectExtensions.Decompose<T, R1, R2>(T, Func<T, R1>, Func<T, R2>)
ObjectExtensions.Decompose<T, R1, R2>(T, ValueFunc<T, R1>, ValueFunc<T, R2>)
LockAcquisition.AcquireReadLock<T>(T)
LockAcquisition.AcquireReadLock<T>(T, TimeSpan)
LockAcquisition.AcquireWriteLock<T>(T)
LockAcquisition.AcquireWriteLock<T>(T, TimeSpan)
LockAcquisition.AcquireUpgradeableReadLock<T>(T)
LockAcquisition.AcquireUpgradeableReadLock<T>(T, TimeSpan)
  • Improve this Doc
  • View Source
Back to top Generated by DocFX