Table of Contents

Class MethodDetourInfo

Namespace
MonoMod.RuntimeDetour
Assembly
MonoMod.RuntimeDetour.dll
A type which represents a single method, and permits access to the detours applied to that method.
public sealed class MethodDetourInfo
Inheritance
MethodDetourInfo

Properties

Detours
Gets the detours applied to this function.
FirstDetour
Gets the first detour in the detour chain.
HasActiveCall
Gets whether or not there are any active calls to this function.
ILHooks
Gets the ILHooks applied to this function.
IsDetoured
Gets whether or not this function is currently detoured.
Method
Gets the method which this object represents.

Methods

EnterLock(ref bool)
Takes the lock for this method. The detour chain will not be modified by other threads while this is held.
ExitLock()
Releases the lock for this method. Must be called only if EnterLock(ref bool)'s lockTaken was true
WithLock()
Takes the lock for this function, and returns a disposable object to automatically release the lock as needed in a using block.

Events

DetourApplied
An event which is invoked whenever a detour is applied to this function.
DetourUndone
An event which is invoked whenver a detour is undone on this function.
ILHookApplied
An event which is invoked whenever an ILHook is applied to this function.
ILHookUndone
An event which is invoked whenver an ILHook is undone on this function.