Files
pardeike-Harmony/docs/api/HarmonyLib.AccessTools.html
T
2020-01-21 01:10:38 +00:00

3263 lines
140 KiB
HTML

<!DOCTYPE html>
<!--[if IE]><![endif]-->
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Class AccessTools
</title>
<meta name="viewport" content="width=device-width">
<meta name="title" content="Class AccessTools
">
<meta name="generator" content="docfx 2.48.1.0">
<link rel="shortcut icon" href="../favicon.ico">
<link rel="stylesheet" href="../styles/docfx.vendor.css">
<link rel="stylesheet" href="../styles/docfx.css">
<link rel="stylesheet" href="../styles/main.css">
<meta property="docfx:navrel" content="../toc.html">
<meta property="docfx:tocrel" content="toc.html">
</head>
<body data-spy="scroll" data-target="#affix" data-offset="120">
<div id="wrapper">
<header>
<nav id="autocollapse" class="navbar navbar-inverse ng-scope" role="navigation">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="../index.html">
<img id="logo" class="svg" src="../logo.svg" alt="">
</a>
</div>
<div class="collapse navbar-collapse" id="navbar">
<form class="navbar-form navbar-right" role="search" id="search">
<div class="form-group">
<input type="text" class="form-control" id="search-query" placeholder="Search" autocomplete="off">
</div>
</form>
</div>
</div>
</nav>
<div class="subnav navbar navbar-default">
<div class="container hide-when-search" id="breadcrumb">
<ul class="breadcrumb">
<li></li>
</ul>
</div>
</div>
</header>
<div role="main" class="container body-content hide-when-search">
<div class="sidenav hide-when-search">
<a class="btn toc-toggle collapse" data-toggle="collapse" href="#sidetoggle" aria-expanded="false" aria-controls="sidetoggle">Show / Hide Table of Contents</a>
<div class="sidetoggle collapse" id="sidetoggle">
<div id="sidetoc"></div>
</div>
</div>
<div class="article row grid-right">
<div class="col-md-10">
<article class="content wrap" id="_content" data-uid="HarmonyLib.AccessTools">
<h1 id="HarmonyLib_AccessTools" data-uid="HarmonyLib.AccessTools" class="text-break">Class AccessTools
</h1>
<div class="markdown level0 summary"><p>A helper class for reflection related functions</p>
</div>
<div class="markdown level0 conceptual"></div>
<div class="inheritance">
<h5>Inheritance</h5>
<div class="level0"><span class="xref">System.Object</span></div>
<div class="level1"><span class="xref">AccessTools</span></div>
</div>
<div class="inheritedMembers">
<h5>Inherited Members</h5>
<div>
<span class="xref">System.Object.ToString()</span>
</div>
<div>
<span class="xref">System.Object.Equals(System.Object)</span>
</div>
<div>
<span class="xref">System.Object.Equals(System.Object, System.Object)</span>
</div>
<div>
<span class="xref">System.Object.ReferenceEquals(System.Object, System.Object)</span>
</div>
<div>
<span class="xref">System.Object.GetHashCode()</span>
</div>
<div>
<span class="xref">System.Object.GetType()</span>
</div>
<div>
<span class="xref">System.Object.MemberwiseClone()</span>
</div>
</div>
<h6><strong>Namespace</strong>: <a class="xref" href="HarmonyLib.html">HarmonyLib</a></h6>
<h6><strong>Assembly</strong>: 0Harmony.dll</h6>
<h5 id="HarmonyLib_AccessTools_syntax">Syntax</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static class AccessTools</code></pre>
</div>
<h3 id="fields">Fields
</h3>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_all.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.all%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L16">View Source</a>
</span>
<h4 id="HarmonyLib_AccessTools_all" data-uid="HarmonyLib.AccessTools.all">all</h4>
<div class="markdown level1 summary"><p>Shortcut to simplify the use of reflections and make it work for any access level</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static BindingFlags all</code></pre>
</div>
<h5 class="fieldValue">Field Value</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.BindingFlags</span></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_allDeclared.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.allDeclared%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L26">View Source</a>
</span>
<h4 id="HarmonyLib_AccessTools_allDeclared" data-uid="HarmonyLib.AccessTools.allDeclared">allDeclared</h4>
<div class="markdown level1 summary"><p>Shortcut to simplify the use of reflections and make it work for any access level but only within the current type</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static BindingFlags allDeclared</code></pre>
</div>
<h5 class="fieldValue">Field Value</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.BindingFlags</span></td>
<td></td>
</tr>
</tbody>
</table>
<h3 id="methods">Methods
</h3>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_ActualParameters_System_Reflection_MethodBase_System_Object___.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.ActualParameters(System.Reflection.MethodBase%2CSystem.Object%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L724">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_ActualParameters_" data-uid="HarmonyLib.AccessTools.ActualParameters*"></a>
<h4 id="HarmonyLib_AccessTools_ActualParameters_System_Reflection_MethodBase_System_Object___" data-uid="HarmonyLib.AccessTools.ActualParameters(System.Reflection.MethodBase,System.Object[])">ActualParameters(MethodBase, Object[])</h4>
<div class="markdown level1 summary"><p>Creates an array of input parameters for a given method and a given set of potential inputs</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static object[] ActualParameters(MethodBase method, object[] inputs)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodBase</span></td>
<td><span class="parametername">method</span></td>
<td><p>The method you are planing to call</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Object</span>[]</td>
<td><span class="parametername">inputs</span></td>
<td><p>The possible input parameters in any order</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span>[]</td>
<td><p>An object array matching the method signature</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_Constructor_System_Type_System_Type___.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.Constructor(System.Type%2CSystem.Type%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L510">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_Constructor_" data-uid="HarmonyLib.AccessTools.Constructor*"></a>
<h4 id="HarmonyLib_AccessTools_Constructor_System_Type_System_Type___" data-uid="HarmonyLib.AccessTools.Constructor(System.Type,System.Type[])">Constructor(Type, Type[])</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a constructor by searching the type and all its super types</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static ConstructorInfo Constructor(Type type, Type[] parameters = null)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the constructor is declared</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><span class="parametername">parameters</span></td>
<td><p>Optional parameters to target a specific overload of the method</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.ConstructorInfo</span></td>
<td><p>A ConstructorInfo or null when type is null or when the method cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_CreateInstance_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.CreateInstance(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L906">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_CreateInstance_" data-uid="HarmonyLib.AccessTools.CreateInstance*"></a>
<h4 id="HarmonyLib_AccessTools_CreateInstance_System_Type_" data-uid="HarmonyLib.AccessTools.CreateInstance(System.Type)">CreateInstance(Type)</h4>
<div class="markdown level1 summary"><p>Creates an (possibly uninitialized) instance of a given type</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static object CreateInstance(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span></td>
<td><p>The new instance</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_DeclaredConstructor_System_Type_System_Type___.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.DeclaredConstructor(System.Type%2CSystem.Type%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L493">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_DeclaredConstructor_" data-uid="HarmonyLib.AccessTools.DeclaredConstructor*"></a>
<h4 id="HarmonyLib_AccessTools_DeclaredConstructor_System_Type_System_Type___" data-uid="HarmonyLib.AccessTools.DeclaredConstructor(System.Type,System.Type[])">DeclaredConstructor(Type, Type[])</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a directly declared constructor</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static ConstructorInfo DeclaredConstructor(Type type, Type[] parameters = null)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the constructor is declared</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><span class="parametername">parameters</span></td>
<td><p>Optional parameters to target a specific overload of the constructor</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.ConstructorInfo</span></td>
<td><p>A ConstructorInfo or null when type is null or when the constructor cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_DeclaredField_System_Type_System_Int32_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.DeclaredField(System.Type%2CSystem.Int32)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L158">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_DeclaredField_" data-uid="HarmonyLib.AccessTools.DeclaredField*"></a>
<h4 id="HarmonyLib_AccessTools_DeclaredField_System_Type_System_Int32_" data-uid="HarmonyLib.AccessTools.DeclaredField(System.Type,System.Int32)">DeclaredField(Type, Int32)</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a field</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static FieldInfo DeclaredField(Type type, int idx)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the field is declared</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Int32</span></td>
<td><span class="parametername">idx</span></td>
<td><p>The zero-based index of the field inside the class definition</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.FieldInfo</span></td>
<td><p>A FieldInfo or null when type is null or when the field cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_DeclaredField_System_Type_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.DeclaredField(System.Type%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L108">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_DeclaredField_" data-uid="HarmonyLib.AccessTools.DeclaredField*"></a>
<h4 id="HarmonyLib_AccessTools_DeclaredField_System_Type_System_String_" data-uid="HarmonyLib.AccessTools.DeclaredField(System.Type,System.String)">DeclaredField(Type, String)</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a directly declared field</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static FieldInfo DeclaredField(Type type, string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the field is defined</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name of the field</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.FieldInfo</span></td>
<td><p>A FieldInfo or null when type/name is null or when the field cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_DeclaredMethod_System_Type_System_String_System_Type___System_Type___.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.DeclaredMethod(System.Type%2CSystem.String%2CSystem.Type%5B%5D%2CSystem.Type%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L269">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_DeclaredMethod_" data-uid="HarmonyLib.AccessTools.DeclaredMethod*"></a>
<h4 id="HarmonyLib_AccessTools_DeclaredMethod_System_Type_System_String_System_Type___System_Type___" data-uid="HarmonyLib.AccessTools.DeclaredMethod(System.Type,System.String,System.Type[],System.Type[])">DeclaredMethod(Type, String, Type[], Type[])</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a directly declared method</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static MethodInfo DeclaredMethod(Type type, string name, Type[] parameters = null, Type[] generics = null)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the method is declared</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name of the method (case sensitive)</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><span class="parametername">parameters</span></td>
<td><p>Optional parameters to target a specific overload of the method</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><span class="parametername">generics</span></td>
<td><p>Optional list of types that define the generic version of the method</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodInfo</span></td>
<td><p>A MethodInfo or null when type/name is null or when the method cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_DeclaredProperty_System_Type_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.DeclaredProperty(System.Type%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L177">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_DeclaredProperty_" data-uid="HarmonyLib.AccessTools.DeclaredProperty*"></a>
<h4 id="HarmonyLib_AccessTools_DeclaredProperty_System_Type_System_String_" data-uid="HarmonyLib.AccessTools.DeclaredProperty(System.Type,System.String)">DeclaredProperty(Type, String)</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a directly declared property</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static PropertyInfo DeclaredProperty(Type type, string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the property is declared</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name of the property (case sensitive)</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.PropertyInfo</span></td>
<td><p>A PropertyInfo or null when type/name is null or when the property cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_DeclaredPropertyGetter_System_Type_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.DeclaredPropertyGetter(System.Type%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L202">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_DeclaredPropertyGetter_" data-uid="HarmonyLib.AccessTools.DeclaredPropertyGetter*"></a>
<h4 id="HarmonyLib_AccessTools_DeclaredPropertyGetter_System_Type_System_String_" data-uid="HarmonyLib.AccessTools.DeclaredPropertyGetter(System.Type,System.String)">DeclaredPropertyGetter(Type, String)</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for the getter method of a directly declared property</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static MethodInfo DeclaredPropertyGetter(Type type, string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the property is declared</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name of the property (case sensitive)</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodInfo</span></td>
<td><p>A MethodInfo or null when type/name is null or when the property cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_DeclaredPropertySetter_System_Type_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.DeclaredPropertySetter(System.Type%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L212">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_DeclaredPropertySetter_" data-uid="HarmonyLib.AccessTools.DeclaredPropertySetter*"></a>
<h4 id="HarmonyLib_AccessTools_DeclaredPropertySetter_System_Type_System_String_" data-uid="HarmonyLib.AccessTools.DeclaredPropertySetter(System.Type,System.String)">DeclaredPropertySetter(Type, String)</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for the setter method of a directly declared property</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static MethodInfo DeclaredPropertySetter(Type type, string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the property is declared</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name of the property (case sensitive)</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodInfo</span></td>
<td><p>A MethodInfo or null when type/name is null or when the property cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_Field_System_Type_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.Field(System.Type%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L133">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_Field_" data-uid="HarmonyLib.AccessTools.Field*"></a>
<h4 id="HarmonyLib_AccessTools_Field_System_Type_System_String_" data-uid="HarmonyLib.AccessTools.Field(System.Type,System.String)">Field(Type, String)</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a field by searching the type and all its super types</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static FieldInfo Field(Type type, string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the field is defined</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name of the field (case sensitive)</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.FieldInfo</span></td>
<td><p>A FieldInfo or null when type/name is null or when the field cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_FieldRefAccess__2___0_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.FieldRefAccess%60%602(%60%600%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L767">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_FieldRefAccess_" data-uid="HarmonyLib.AccessTools.FieldRefAccess*"></a>
<h4 id="HarmonyLib_AccessTools_FieldRefAccess__2___0_System_String_" data-uid="HarmonyLib.AccessTools.FieldRefAccess``2(``0,System.String)">FieldRefAccess&lt;T, F&gt;(T, String)</h4>
<div class="markdown level1 summary"><p>Creates an instance field reference for a specific instance</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static F FieldRefAccess&lt;T, F&gt;(T instance, string fieldName)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">T</span></td>
<td><span class="parametername">instance</span></td>
<td><p>The instance</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">fieldName</span></td>
<td><p>The name of the field</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">F</span></td>
<td><p>An readable/assignable object representing the field</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">T</span></td>
<td><p>The class the field is defined in or &quot;object&quot; if type cannot be accessed at compile time</p>
</td>
</tr>
<tr>
<td><span class="parametername">F</span></td>
<td><p>The type of the field</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_FieldRefAccess__2_System_Reflection_FieldInfo_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.FieldRefAccess%60%602(System.Reflection.FieldInfo)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L778">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_FieldRefAccess_" data-uid="HarmonyLib.AccessTools.FieldRefAccess*"></a>
<h4 id="HarmonyLib_AccessTools_FieldRefAccess__2_System_Reflection_FieldInfo_" data-uid="HarmonyLib.AccessTools.FieldRefAccess``2(System.Reflection.FieldInfo)">FieldRefAccess&lt;T, F&gt;(FieldInfo)</h4>
<div class="markdown level1 summary"><p>Creates an instance field reference delegate</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static AccessTools.FieldRef&lt;T, F&gt; FieldRefAccess&lt;T, F&gt;(FieldInfo fieldInfo)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.FieldInfo</span></td>
<td><span class="parametername">fieldInfo</span></td>
<td><p>FieldInfo for the field</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="HarmonyLib.AccessTools.FieldRef-2.html">AccessTools.FieldRef</a>&lt;T, F&gt;</td>
<td><p>A read and writable field reference delegate</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">T</span></td>
<td><p>The class the field is defined in or &quot;object&quot; if type cannot be accessed at compile time</p>
</td>
</tr>
<tr>
<td><span class="parametername">F</span></td>
<td><p>The type of the field</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_FieldRefAccess__2_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.FieldRefAccess%60%602(System.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L750">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_FieldRefAccess_" data-uid="HarmonyLib.AccessTools.FieldRefAccess*"></a>
<h4 id="HarmonyLib_AccessTools_FieldRefAccess__2_System_String_" data-uid="HarmonyLib.AccessTools.FieldRefAccess``2(System.String)">FieldRefAccess&lt;T, F&gt;(String)</h4>
<div class="markdown level1 summary"><p>Creates an instance field reference</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static AccessTools.FieldRef&lt;T, F&gt; FieldRefAccess&lt;T, F&gt;(string fieldName)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">fieldName</span></td>
<td><p>The name of the field</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="HarmonyLib.AccessTools.FieldRef-2.html">AccessTools.FieldRef</a>&lt;T, F&gt;</td>
<td><p>A read and writable field reference delegate</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">T</span></td>
<td><p>The class the field is defined in or &quot;object&quot; if type cannot be accessed at compile time</p>
</td>
</tr>
<tr>
<td><span class="parametername">F</span></td>
<td><p>The type of the field</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_FindIncludingBaseTypes__1_System_Type_System_Func_System_Type___0__.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.FindIncludingBaseTypes%60%601(System.Type%2CSystem.Func%7BSystem.Type%2C%60%600%7D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L67">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_FindIncludingBaseTypes_" data-uid="HarmonyLib.AccessTools.FindIncludingBaseTypes*"></a>
<h4 id="HarmonyLib_AccessTools_FindIncludingBaseTypes__1_System_Type_System_Func_System_Type___0__" data-uid="HarmonyLib.AccessTools.FindIncludingBaseTypes``1(System.Type,System.Func{System.Type,``0})">FindIncludingBaseTypes&lt;T&gt;(Type, Func&lt;Type, T&gt;)</h4>
<div class="markdown level1 summary"><p>Applies a function going up the type hierarchy and stops at the first non null result</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static T FindIncludingBaseTypes&lt;T&gt;(Type type, Func&lt;Type, T&gt; func)
where T : class</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type to start with</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Func</span>&lt;<span class="xref">System.Type</span>, T&gt;</td>
<td><span class="parametername">func</span></td>
<td><p>The evaluation function returning T</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">T</span></td>
<td><p>Returns the first non null result or default(T) when reaching the top level type object</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">T</span></td>
<td><p>Result type of func()</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_FindIncludingInnerTypes__1_System_Type_System_Func_System_Type___0__.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.FindIncludingInnerTypes%60%601(System.Type%2CSystem.Func%7BSystem.Type%2C%60%600%7D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L86">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_FindIncludingInnerTypes_" data-uid="HarmonyLib.AccessTools.FindIncludingInnerTypes*"></a>
<h4 id="HarmonyLib_AccessTools_FindIncludingInnerTypes__1_System_Type_System_Func_System_Type___0__" data-uid="HarmonyLib.AccessTools.FindIncludingInnerTypes``1(System.Type,System.Func{System.Type,``0})">FindIncludingInnerTypes&lt;T&gt;(Type, Func&lt;Type, T&gt;)</h4>
<div class="markdown level1 summary"><p>Applies a function going into inner types and stops at the first non null result</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static T FindIncludingInnerTypes&lt;T&gt;(Type type, Func&lt;Type, T&gt; func)
where T : class</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type to start with</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Func</span>&lt;<span class="xref">System.Type</span>, T&gt;</td>
<td><span class="parametername">func</span></td>
<td><p>The evaluation function returning T</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">T</span></td>
<td><p>Returns the first non null result or null with no match</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">T</span></td>
<td><p>Generic type parameter</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_FirstConstructor_System_Type_System_Func_System_Reflection_ConstructorInfo_System_Boolean__.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.FirstConstructor(System.Type%2CSystem.Func%7BSystem.Reflection.ConstructorInfo%2CSystem.Boolean%7D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L670">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_FirstConstructor_" data-uid="HarmonyLib.AccessTools.FirstConstructor*"></a>
<h4 id="HarmonyLib_AccessTools_FirstConstructor_System_Type_System_Func_System_Reflection_ConstructorInfo_System_Boolean__" data-uid="HarmonyLib.AccessTools.FirstConstructor(System.Type,System.Func{System.Reflection.ConstructorInfo,System.Boolean})">FirstConstructor(Type, Func&lt;ConstructorInfo, Boolean&gt;)</h4>
<div class="markdown level1 summary"><p>Given a type, returns the first constructor matching a predicate</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static ConstructorInfo FirstConstructor(Type type, Func&lt;ConstructorInfo, bool&gt; predicate)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type to start searching at</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Func</span>&lt;<span class="xref">System.Reflection.ConstructorInfo</span>, <span class="xref">System.Boolean</span>&gt;</td>
<td><span class="parametername">predicate</span></td>
<td><p>The predicate to search with</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.ConstructorInfo</span></td>
<td><p>The ConstructorInfo or null if type/predicate is null or if a type with that name cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_FirstInner_System_Type_System_Func_System_Type_System_Boolean__.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.FirstInner(System.Type%2CSystem.Func%7BSystem.Type%2CSystem.Boolean%7D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L626">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_FirstInner_" data-uid="HarmonyLib.AccessTools.FirstInner*"></a>
<h4 id="HarmonyLib_AccessTools_FirstInner_System_Type_System_Func_System_Type_System_Boolean__" data-uid="HarmonyLib.AccessTools.FirstInner(System.Type,System.Func{System.Type,System.Boolean})">FirstInner(Type, Func&lt;Type, Boolean&gt;)</h4>
<div class="markdown level1 summary"><p>Given a type, returns the first inner type matching a recursive search with a predicate</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Type FirstInner(Type type, Func&lt;Type, bool&gt; predicate)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type to start searching at</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Func</span>&lt;<span class="xref">System.Type</span>, <span class="xref">System.Boolean</span>&gt;</td>
<td><span class="parametername">predicate</span></td>
<td><p>The predicate to search with</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><p>The inner type or null if type/predicate is null or if a type with that name cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_FirstMethod_System_Type_System_Func_System_Reflection_MethodInfo_System_Boolean__.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.FirstMethod(System.Type%2CSystem.Func%7BSystem.Reflection.MethodInfo%2CSystem.Boolean%7D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L648">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_FirstMethod_" data-uid="HarmonyLib.AccessTools.FirstMethod*"></a>
<h4 id="HarmonyLib_AccessTools_FirstMethod_System_Type_System_Func_System_Reflection_MethodInfo_System_Boolean__" data-uid="HarmonyLib.AccessTools.FirstMethod(System.Type,System.Func{System.Reflection.MethodInfo,System.Boolean})">FirstMethod(Type, Func&lt;MethodInfo, Boolean&gt;)</h4>
<div class="markdown level1 summary"><p>Given a type, returns the first method matching a predicate</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static MethodInfo FirstMethod(Type type, Func&lt;MethodInfo, bool&gt; predicate)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type to start searching at</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Func</span>&lt;<span class="xref">System.Reflection.MethodInfo</span>, <span class="xref">System.Boolean</span>&gt;</td>
<td><span class="parametername">predicate</span></td>
<td><p>The predicate to search with</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodInfo</span></td>
<td><p>The MethodInfo or null if type/predicate is null or if a type with that name cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_FirstProperty_System_Type_System_Func_System_Reflection_PropertyInfo_System_Boolean__.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.FirstProperty(System.Type%2CSystem.Func%7BSystem.Reflection.PropertyInfo%2CSystem.Boolean%7D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L692">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_FirstProperty_" data-uid="HarmonyLib.AccessTools.FirstProperty*"></a>
<h4 id="HarmonyLib_AccessTools_FirstProperty_System_Type_System_Func_System_Reflection_PropertyInfo_System_Boolean__" data-uid="HarmonyLib.AccessTools.FirstProperty(System.Type,System.Func{System.Reflection.PropertyInfo,System.Boolean})">FirstProperty(Type, Func&lt;PropertyInfo, Boolean&gt;)</h4>
<div class="markdown level1 summary"><p>Given a type, returns the first property matching a predicate</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static PropertyInfo FirstProperty(Type type, Func&lt;PropertyInfo, bool&gt; predicate)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type to start searching at</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Func</span>&lt;<span class="xref">System.Reflection.PropertyInfo</span>, <span class="xref">System.Boolean</span>&gt;</td>
<td><span class="parametername">predicate</span></td>
<td><p>The predicate to search with</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.PropertyInfo</span></td>
<td><p>The PropertyInfo or null if type/predicate is null or if a type with that name cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetDeclaredConstructors_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetDeclaredConstructors(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L526">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetDeclaredConstructors_" data-uid="HarmonyLib.AccessTools.GetDeclaredConstructors*"></a>
<h4 id="HarmonyLib_AccessTools_GetDeclaredConstructors_System_Type_" data-uid="HarmonyLib.AccessTools.GetDeclaredConstructors(System.Type)">GetDeclaredConstructors(Type)</h4>
<div class="markdown level1 summary"><p>Gets reflection information for all declared constructors</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;ConstructorInfo&gt; GetDeclaredConstructors(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the constructors are declared</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.Reflection.ConstructorInfo</span>&gt;</td>
<td><p>A list of ConstructorInfo</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetDeclaredFields_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetDeclaredFields(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L571">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetDeclaredFields_" data-uid="HarmonyLib.AccessTools.GetDeclaredFields*"></a>
<h4 id="HarmonyLib_AccessTools_GetDeclaredFields_System_Type_" data-uid="HarmonyLib.AccessTools.GetDeclaredFields(System.Type)">GetDeclaredFields(Type)</h4>
<div class="markdown level1 summary"><p>Gets reflection information for all declared fields</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;FieldInfo&gt; GetDeclaredFields(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the fields are declared</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.Reflection.FieldInfo</span>&gt;</td>
<td><p>A list of FieldInfo</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetDeclaredMethods_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetDeclaredMethods(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L541">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetDeclaredMethods_" data-uid="HarmonyLib.AccessTools.GetDeclaredMethods*"></a>
<h4 id="HarmonyLib_AccessTools_GetDeclaredMethods_System_Type_" data-uid="HarmonyLib.AccessTools.GetDeclaredMethods(System.Type)">GetDeclaredMethods(Type)</h4>
<div class="markdown level1 summary"><p>Gets reflection information for all declared methods</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;MethodInfo&gt; GetDeclaredMethods(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the methods are declared</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.Reflection.MethodInfo</span>&gt;</td>
<td><p>A list of MethodInfo</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetDeclaredProperties_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetDeclaredProperties(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L556">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetDeclaredProperties_" data-uid="HarmonyLib.AccessTools.GetDeclaredProperties*"></a>
<h4 id="HarmonyLib_AccessTools_GetDeclaredProperties_System_Type_" data-uid="HarmonyLib.AccessTools.GetDeclaredProperties(System.Type)">GetDeclaredProperties(Type)</h4>
<div class="markdown level1 summary"><p>Gets reflection information for all declared properties</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;PropertyInfo&gt; GetDeclaredProperties(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the properties are declared</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.Reflection.PropertyInfo</span>&gt;</td>
<td><p>A list of PropertyInfo</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetDefaultValue_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetDefaultValue(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L888">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetDefaultValue_" data-uid="HarmonyLib.AccessTools.GetDefaultValue*"></a>
<h4 id="HarmonyLib_AccessTools_GetDefaultValue_System_Type_" data-uid="HarmonyLib.AccessTools.GetDefaultValue(System.Type)">GetDefaultValue(Type)</h4>
<div class="markdown level1 summary"><p>Gets default value for a specific type</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static object GetDefaultValue(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span></td>
<td><p>The default value</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetFieldNames_System_Object_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetFieldNames(System.Object)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L426">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetFieldNames_" data-uid="HarmonyLib.AccessTools.GetFieldNames*"></a>
<h4 id="HarmonyLib_AccessTools_GetFieldNames_System_Object_" data-uid="HarmonyLib.AccessTools.GetFieldNames(System.Object)">GetFieldNames(Object)</h4>
<div class="markdown level1 summary"><p>Gets the names of all fields that are declared in the type of the instance</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;string&gt; GetFieldNames(object instance)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span></td>
<td><span class="parametername">instance</span></td>
<td><p>An instance of the type to search in</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.String</span>&gt;</td>
<td><p>A list of field names</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetFieldNames_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetFieldNames(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L411">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetFieldNames_" data-uid="HarmonyLib.AccessTools.GetFieldNames*"></a>
<h4 id="HarmonyLib_AccessTools_GetFieldNames_System_Type_" data-uid="HarmonyLib.AccessTools.GetFieldNames(System.Type)">GetFieldNames(Type)</h4>
<div class="markdown level1 summary"><p>Gets the names of all fields that are declared in a type</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;string&gt; GetFieldNames(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The declaring type</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.String</span>&gt;</td>
<td><p>A list of field names</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetMethodNames_System_Object_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetMethodNames(System.Object)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L396">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetMethodNames_" data-uid="HarmonyLib.AccessTools.GetMethodNames*"></a>
<h4 id="HarmonyLib_AccessTools_GetMethodNames_System_Object_" data-uid="HarmonyLib.AccessTools.GetMethodNames(System.Object)">GetMethodNames(Object)</h4>
<div class="markdown level1 summary"><p>Gets the names of all method that are declared in the type of the instance</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;string&gt; GetMethodNames(object instance)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span></td>
<td><span class="parametername">instance</span></td>
<td><p>An instance of the type to search in</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.String</span>&gt;</td>
<td><p>A list of method names</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetMethodNames_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetMethodNames(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L381">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetMethodNames_" data-uid="HarmonyLib.AccessTools.GetMethodNames*"></a>
<h4 id="HarmonyLib_AccessTools_GetMethodNames_System_Type_" data-uid="HarmonyLib.AccessTools.GetMethodNames(System.Type)">GetMethodNames(Type)</h4>
<div class="markdown level1 summary"><p>Gets the names of all method that are declared in a type</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;string&gt; GetMethodNames(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The declaring type</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.String</span>&gt;</td>
<td><p>A list of method names</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetOutsideCaller.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetOutsideCaller%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L861">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetOutsideCaller_" data-uid="HarmonyLib.AccessTools.GetOutsideCaller*"></a>
<h4 id="HarmonyLib_AccessTools_GetOutsideCaller" data-uid="HarmonyLib.AccessTools.GetOutsideCaller">GetOutsideCaller()</h4>
<div class="markdown level1 summary"><p>Returns who called the current method</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static MethodBase GetOutsideCaller()</code></pre>
</div>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodBase</span></td>
<td><p>The calling method (excluding the current method)</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetPropertyNames_System_Object_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetPropertyNames(System.Object)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L456">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetPropertyNames_" data-uid="HarmonyLib.AccessTools.GetPropertyNames*"></a>
<h4 id="HarmonyLib_AccessTools_GetPropertyNames_System_Object_" data-uid="HarmonyLib.AccessTools.GetPropertyNames(System.Object)">GetPropertyNames(Object)</h4>
<div class="markdown level1 summary"><p>Gets the names of all properties that are declared in the type of the instance</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;string&gt; GetPropertyNames(object instance)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span></td>
<td><span class="parametername">instance</span></td>
<td><p>An instance of the type to search in</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.String</span>&gt;</td>
<td><p>A list of property names</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetPropertyNames_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetPropertyNames(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L441">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetPropertyNames_" data-uid="HarmonyLib.AccessTools.GetPropertyNames*"></a>
<h4 id="HarmonyLib_AccessTools_GetPropertyNames_System_Type_" data-uid="HarmonyLib.AccessTools.GetPropertyNames(System.Type)">GetPropertyNames(Type)</h4>
<div class="markdown level1 summary"><p>Gets the names of all properties that are declared in a type</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static List&lt;string&gt; GetPropertyNames(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The declaring type</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Collections.Generic.List</span>&lt;<span class="xref">System.String</span>&gt;</td>
<td><p>A list of property names</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetReturnedType_System_Reflection_MethodBase_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetReturnedType(System.Reflection.MethodBase)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L586">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetReturnedType_" data-uid="HarmonyLib.AccessTools.GetReturnedType*"></a>
<h4 id="HarmonyLib_AccessTools_GetReturnedType_System_Reflection_MethodBase_" data-uid="HarmonyLib.AccessTools.GetReturnedType(System.Reflection.MethodBase)">GetReturnedType(MethodBase)</h4>
<div class="markdown level1 summary"><p>Gets the return type of a method or constructor</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Type GetReturnedType(MethodBase methodOrConstructor)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodBase</span></td>
<td><span class="parametername">methodOrConstructor</span></td>
<td><p>The method or constructor</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><p>The return type of the method</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetTypes_System_Object___.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetTypes(System.Object%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L713">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetTypes_" data-uid="HarmonyLib.AccessTools.GetTypes*"></a>
<h4 id="HarmonyLib_AccessTools_GetTypes_System_Object___" data-uid="HarmonyLib.AccessTools.GetTypes(System.Object[])">GetTypes(Object[])</h4>
<div class="markdown level1 summary"><p>Returns an array containing the type of each object in the given array</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Type[] GetTypes(object[] parameters)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span>[]</td>
<td><span class="parametername">parameters</span></td>
<td><p>An array of objects</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><p>An array of types or an empty array if parameters is null (if an object is null, the type for it will be object)</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetTypesFromAssembly_System_Reflection_Assembly_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetTypesFromAssembly(System.Reflection.Assembly)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L52">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetTypesFromAssembly_" data-uid="HarmonyLib.AccessTools.GetTypesFromAssembly*"></a>
<h4 id="HarmonyLib_AccessTools_GetTypesFromAssembly_System_Reflection_Assembly_" data-uid="HarmonyLib.AccessTools.GetTypesFromAssembly(System.Reflection.Assembly)">GetTypesFromAssembly(Assembly)</h4>
<div class="markdown level1 summary"><p>Gets all type by name from a given assembly. This is a wrapper that respects different .NET versions</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Type[] GetTypesFromAssembly(Assembly assembly)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.Assembly</span></td>
<td><span class="parametername">assembly</span></td>
<td><p>The assembly</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><p>A Type array</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_GetUnderlyingType_System_Reflection_MemberInfo_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.GetUnderlyingType(System.Reflection.MemberInfo)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L471">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_GetUnderlyingType_" data-uid="HarmonyLib.AccessTools.GetUnderlyingType*"></a>
<h4 id="HarmonyLib_AccessTools_GetUnderlyingType_System_Reflection_MemberInfo_" data-uid="HarmonyLib.AccessTools.GetUnderlyingType(System.Reflection.MemberInfo)">GetUnderlyingType(MemberInfo)</h4>
<div class="markdown level1 summary"><p>Gets the type of any member of a class</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Type GetUnderlyingType(this MemberInfo member)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MemberInfo</span></td>
<td><span class="parametername">member</span></td>
<td><p>An EventInfo, FieldInfo, MethodInfo, or PropertyInfo</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><p>The type that represents the output of this member</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_Inner_System_Type_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.Inner(System.Type%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L604">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_Inner_" data-uid="HarmonyLib.AccessTools.Inner*"></a>
<h4 id="HarmonyLib_AccessTools_Inner_System_Type_System_String_" data-uid="HarmonyLib.AccessTools.Inner(System.Type,System.String)">Inner(Type, String)</h4>
<div class="markdown level1 summary"><p>Given a type, returns the first inner type matching a recursive search by name</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Type Inner(Type type, string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type to start searching at</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name of the inner type (case sensitive)</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><p>The inner type or null if type/name is null or if a type with that name cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_IsClass_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.IsClass(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L1024">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_IsClass_" data-uid="HarmonyLib.AccessTools.IsClass*"></a>
<h4 id="HarmonyLib_AccessTools_IsClass_System_Type_" data-uid="HarmonyLib.AccessTools.IsClass(System.Type)">IsClass(Type)</h4>
<div class="markdown level1 summary"><p>Tests if a type is a class</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static bool IsClass(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><p>True if the type is a class</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_IsOfNullableType__1___0_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.IsOfNullableType%60%601(%60%600)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L1053">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_IsOfNullableType_" data-uid="HarmonyLib.AccessTools.IsOfNullableType*"></a>
<h4 id="HarmonyLib_AccessTools_IsOfNullableType__1___0_" data-uid="HarmonyLib.AccessTools.IsOfNullableType``1(``0)">IsOfNullableType&lt;T&gt;(T)</h4>
<div class="markdown level1 summary"><p>Test whether an instance is of a nullable type</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static bool IsOfNullableType&lt;T&gt;(T instance)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">T</span></td>
<td><span class="parametername">instance</span></td>
<td><p>An instance to test</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><p>True if instance is of nullable type, false if not</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">T</span></td>
<td><p>Type of instance</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_IsStruct_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.IsStruct(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L1015">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_IsStruct_" data-uid="HarmonyLib.AccessTools.IsStruct*"></a>
<h4 id="HarmonyLib_AccessTools_IsStruct_System_Type_" data-uid="HarmonyLib.AccessTools.IsStruct(System.Type)">IsStruct(Type)</h4>
<div class="markdown level1 summary"><p>Tests if a type is a struct</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static bool IsStruct(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><p>True if the type is a struct</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_IsValue_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.IsValue(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L1033">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_IsValue_" data-uid="HarmonyLib.AccessTools.IsValue*"></a>
<h4 id="HarmonyLib_AccessTools_IsValue_System_Type_" data-uid="HarmonyLib.AccessTools.IsValue(System.Type)">IsValue(Type)</h4>
<div class="markdown level1 summary"><p>Tests if a type is a value type</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static bool IsValue(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><p>True if the type is a value type</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_IsVoid_System_Type_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.IsVoid(System.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L1042">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_IsVoid_" data-uid="HarmonyLib.AccessTools.IsVoid*"></a>
<h4 id="HarmonyLib_AccessTools_IsVoid_System_Type_" data-uid="HarmonyLib.AccessTools.IsVoid(System.Type)">IsVoid(Type)</h4>
<div class="markdown level1 summary"><p>Tests if a type is void</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static bool IsVoid(Type type)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><p>True if the type is void</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_MakeDeepCopy_System_Object_System_Type_System_Func_System_String_HarmonyLib_Traverse_HarmonyLib_Traverse_System_Object__System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.MakeDeepCopy(System.Object%2CSystem.Type%2CSystem.Func%7BSystem.String%2CHarmonyLib.Traverse%2CHarmonyLib.Traverse%2CSystem.Object%7D%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L945">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_MakeDeepCopy_" data-uid="HarmonyLib.AccessTools.MakeDeepCopy*"></a>
<h4 id="HarmonyLib_AccessTools_MakeDeepCopy_System_Object_System_Type_System_Func_System_String_HarmonyLib_Traverse_HarmonyLib_Traverse_System_Object__System_String_" data-uid="HarmonyLib.AccessTools.MakeDeepCopy(System.Object,System.Type,System.Func{System.String,HarmonyLib.Traverse,HarmonyLib.Traverse,System.Object},System.String)">MakeDeepCopy(Object, Type, Func&lt;String, Traverse, Traverse, Object&gt;, String)</h4>
<div class="markdown level1 summary"><p>Makes a deep copy of any object</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static object MakeDeepCopy(object source, Type resultType, Func&lt;string, Traverse, Traverse, object&gt; processor = null, string pathRoot = &quot;&quot;)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span></td>
<td><span class="parametername">source</span></td>
<td><p>The original object</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">resultType</span></td>
<td><p>The type of the instance that should be created</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Func</span>&lt;<span class="xref">System.String</span>, <a class="xref" href="HarmonyLib.Traverse.html">Traverse</a>, <a class="xref" href="HarmonyLib.Traverse.html">Traverse</a>, <span class="xref">System.Object</span>&gt;</td>
<td><span class="parametername">processor</span></td>
<td><p>Optional value transformation function (taking a field name and src/dst traverse objects)</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">pathRoot</span></td>
<td><p>The optional path root to start with</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span></td>
<td><p>The copy of the original object</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_MakeDeepCopy__1_System_Object_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.MakeDeepCopy%60%601(System.Object)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L921">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_MakeDeepCopy_" data-uid="HarmonyLib.AccessTools.MakeDeepCopy*"></a>
<h4 id="HarmonyLib_AccessTools_MakeDeepCopy__1_System_Object_" data-uid="HarmonyLib.AccessTools.MakeDeepCopy``1(System.Object)">MakeDeepCopy&lt;T&gt;(Object)</h4>
<div class="markdown level1 summary"><p>Makes a deep copy of any object</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static T MakeDeepCopy&lt;T&gt;(object source)
where T : class</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span></td>
<td><span class="parametername">source</span></td>
<td><p>The original object</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">T</span></td>
<td><p>A copy of the original object but of type T</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">T</span></td>
<td><p>The type of the instance that should be created</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_MakeDeepCopy__1_System_Object___0__System_Func_System_String_HarmonyLib_Traverse_HarmonyLib_Traverse_System_Object__System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.MakeDeepCopy%60%601(System.Object%2C%60%600%40%2CSystem.Func%7BSystem.String%2CHarmonyLib.Traverse%2CHarmonyLib.Traverse%2CSystem.Object%7D%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L933">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_MakeDeepCopy_" data-uid="HarmonyLib.AccessTools.MakeDeepCopy*"></a>
<h4 id="HarmonyLib_AccessTools_MakeDeepCopy__1_System_Object___0__System_Func_System_String_HarmonyLib_Traverse_HarmonyLib_Traverse_System_Object__System_String_" data-uid="HarmonyLib.AccessTools.MakeDeepCopy``1(System.Object,``0@,System.Func{System.String,HarmonyLib.Traverse,HarmonyLib.Traverse,System.Object},System.String)">MakeDeepCopy&lt;T&gt;(Object, out T, Func&lt;String, Traverse, Traverse, Object&gt;, String)</h4>
<div class="markdown level1 summary"><p>Makes a deep copy of any object</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static void MakeDeepCopy&lt;T&gt;(object source, out T result, Func&lt;string, Traverse, Traverse, object&gt; processor = null, string pathRoot = &quot;&quot;)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Object</span></td>
<td><span class="parametername">source</span></td>
<td><p>The original object</p>
</td>
</tr>
<tr>
<td><span class="xref">T</span></td>
<td><span class="parametername">result</span></td>
<td><p>[out] The copy of the original object</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Func</span>&lt;<span class="xref">System.String</span>, <a class="xref" href="HarmonyLib.Traverse.html">Traverse</a>, <a class="xref" href="HarmonyLib.Traverse.html">Traverse</a>, <span class="xref">System.Object</span>&gt;</td>
<td><span class="parametername">processor</span></td>
<td><p>Optional value transformation function (taking a field name and src/dst traverse objects)</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">pathRoot</span></td>
<td><p>The optional path root to start with</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">T</span></td>
<td><p>The type of the instance that should be created</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_Method_System_String_System_Type___System_Type___.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.Method(System.String%2CSystem.Type%5B%5D%2CSystem.Type%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L361">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_Method_" data-uid="HarmonyLib.AccessTools.Method*"></a>
<h4 id="HarmonyLib_AccessTools_Method_System_String_System_Type___System_Type___" data-uid="HarmonyLib.AccessTools.Method(System.String,System.Type[],System.Type[])">Method(String, Type[], Type[])</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a method by searching the type and all its super types</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static MethodInfo Method(string typeColonMethodname, Type[] parameters = null, Type[] generics = null)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">typeColonMethodname</span></td>
<td><p>The full name (Namespace.Type1.Type2:MethodName) of the type where the method is declared</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><span class="parametername">parameters</span></td>
<td><p>Optional parameters to target a specific overload of the method</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><span class="parametername">generics</span></td>
<td><p>Optional list of types that define the generic version of the method</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodInfo</span></td>
<td><p>A MethodInfo or null when type/name is null or when the method cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_Method_System_Type_System_String_System_Type___System_Type___.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.Method(System.Type%2CSystem.String%2CSystem.Type%5B%5D%2CSystem.Type%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L309">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_Method_" data-uid="HarmonyLib.AccessTools.Method*"></a>
<h4 id="HarmonyLib_AccessTools_Method_System_Type_System_String_System_Type___System_Type___" data-uid="HarmonyLib.AccessTools.Method(System.Type,System.String,System.Type[],System.Type[])">Method(Type, String, Type[], Type[])</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a method by searching the type and all its super types</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static MethodInfo Method(Type type, string name, Type[] parameters = null, Type[] generics = null)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class where the method is declared</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name of the method (case sensitive)</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><span class="parametername">parameters</span></td>
<td><p>Optional parameters to target a specific overload of the method</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span>[]</td>
<td><span class="parametername">generics</span></td>
<td><p>Optional list of types that define the generic version of the method</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodInfo</span></td>
<td><p>A MethodInfo or null when type/name is null or when the method cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_Property_System_Type_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.Property(System.Type%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L222">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_Property_" data-uid="HarmonyLib.AccessTools.Property*"></a>
<h4 id="HarmonyLib_AccessTools_Property_System_Type_System_String_" data-uid="HarmonyLib.AccessTools.Property(System.Type,System.String)">Property(Type, String)</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for a property by searching the type and all its super types</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static PropertyInfo Property(Type type, string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.PropertyInfo</span></td>
<td><p>A PropertyInfo or null when type/name is null or when the property cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_PropertyGetter_System_Type_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.PropertyGetter(System.Type%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L247">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_PropertyGetter_" data-uid="HarmonyLib.AccessTools.PropertyGetter*"></a>
<h4 id="HarmonyLib_AccessTools_PropertyGetter_System_Type_System_String_" data-uid="HarmonyLib.AccessTools.PropertyGetter(System.Type,System.String)">PropertyGetter(Type, String)</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for the getter method of a property by searching the type and all its super types</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static MethodInfo PropertyGetter(Type type, string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodInfo</span></td>
<td><p>A MethodInfo or null when type/name is null or when the property cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_PropertySetter_System_Type_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.PropertySetter(System.Type%2CSystem.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L257">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_PropertySetter_" data-uid="HarmonyLib.AccessTools.PropertySetter*"></a>
<h4 id="HarmonyLib_AccessTools_PropertySetter_System_Type_System_String_" data-uid="HarmonyLib.AccessTools.PropertySetter(System.Type,System.String)">PropertySetter(Type, String)</h4>
<div class="markdown level1 summary"><p>Gets the reflection information for the setter method of a property by searching the type and all its super types</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static MethodInfo PropertySetter(Type type, string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The type</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.MethodInfo</span></td>
<td><p>A MethodInfo or null when type/name is null or when the property cannot be found</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_StaticFieldRefAccess__1_System_Reflection_FieldInfo_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.StaticFieldRefAccess%60%601(System.Reflection.FieldInfo)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L834">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_StaticFieldRefAccess_" data-uid="HarmonyLib.AccessTools.StaticFieldRefAccess*"></a>
<h4 id="HarmonyLib_AccessTools_StaticFieldRefAccess__1_System_Reflection_FieldInfo_" data-uid="HarmonyLib.AccessTools.StaticFieldRefAccess``1(System.Reflection.FieldInfo)">StaticFieldRefAccess&lt;F&gt;(FieldInfo)</h4>
<div class="markdown level1 summary"><p>Creates a static field reference delegate</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static AccessTools.FieldRef&lt;F&gt; StaticFieldRefAccess&lt;F&gt;(FieldInfo fieldInfo)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Reflection.FieldInfo</span></td>
<td><span class="parametername">fieldInfo</span></td>
<td><p>FieldInfo for the field</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="HarmonyLib.AccessTools.FieldRef-1.html">AccessTools.FieldRef</a>&lt;F&gt;</td>
<td><p>A read and writable field reference delegate</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">F</span></td>
<td><p>The type of the field</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_StaticFieldRefAccess__2_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.StaticFieldRefAccess%60%602(System.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L819">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_StaticFieldRefAccess_" data-uid="HarmonyLib.AccessTools.StaticFieldRefAccess*"></a>
<h4 id="HarmonyLib_AccessTools_StaticFieldRefAccess__2_System_String_" data-uid="HarmonyLib.AccessTools.StaticFieldRefAccess``2(System.String)">StaticFieldRefAccess&lt;T, F&gt;(String)</h4>
<div class="markdown level1 summary"><p>Creates a static field reference</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static F StaticFieldRefAccess&lt;T, F&gt;(string fieldName)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">fieldName</span></td>
<td><p>The name of the field</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">F</span></td>
<td><p>An readable/assignable object representing the static field</p>
</td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">T</span></td>
<td><p>The class the field is defined in or &quot;object&quot; if type cannot be accessed at compile time</p>
</td>
</tr>
<tr>
<td><span class="parametername">F</span></td>
<td><p>The type of the field</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_ThrowMissingMemberException_System_Type_System_String___.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.ThrowMissingMemberException(System.Type%2CSystem.String%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L877">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_ThrowMissingMemberException_" data-uid="HarmonyLib.AccessTools.ThrowMissingMemberException*"></a>
<h4 id="HarmonyLib_AccessTools_ThrowMissingMemberException_System_Type_System_String___" data-uid="HarmonyLib.AccessTools.ThrowMissingMemberException(System.Type,System.String[])">ThrowMissingMemberException(Type, String[])</h4>
<div class="markdown level1 summary"><p>Throws a missing member runtime exception</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static void ThrowMissingMemberException(Type type, params string[] names)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">type</span></td>
<td><p>The class that is involved</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span>[]</td>
<td><span class="parametername">names</span></td>
<td><p>A list of names</p>
</td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools_TypeByName_System_String_.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools.TypeByName(System.String)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L32">View Source</a>
</span>
<a id="HarmonyLib_AccessTools_TypeByName_" data-uid="HarmonyLib.AccessTools.TypeByName*"></a>
<h4 id="HarmonyLib_AccessTools_TypeByName_System_String_" data-uid="HarmonyLib.AccessTools.TypeByName(System.String)">TypeByName(String)</h4>
<div class="markdown level1 summary"><p>Gets a type by name. Prefers a full name with namespace but falls back to the first type matching the name otherwise</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Type TypeByName(string name)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">name</span></td>
<td><p>The name</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Type</span></td>
<td><p>A Type</p>
</td>
</tr>
</tbody>
</table>
</article>
</div>
<div class="hidden-sm col-md-2" role="complementary">
<div class="sideaffix">
<div class="contribution">
<ul class="nav">
<li>
<a href="https://github.com/pardeike/Harmony/new/master/apiSpec/new?filename=HarmonyLib_AccessTools.md&amp;value=---%0Auid%3A%20HarmonyLib.AccessTools%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A" class="contribution-link">Improve this Doc</a>
</li>
<li>
<a href="https://github.com/pardeike/Harmony/blob/master/Harmony/Tools/AccessTools.cs/#L13" class="contribution-link">View Source</a>
</li>
</ul>
</div>
<nav class="bs-docs-sidebar hidden-print hidden-xs hidden-sm affix" id="affix">
<!-- <p><a class="back-to-top" href="#top">Back to top</a><p> -->
</nav>
</div>
</div>
</div>
</div>
<footer>
<div class="grad-bottom"></div>
<div class="footer">
<div class="container">
<span class="pull-right">
<a href="#top">Back to top</a>
</span>
<span>Generated by <strong>DocFX</strong></span>
</div>
</div>
</footer>
</div>
<script type="text/javascript" src="../styles/docfx.vendor.js"></script>
<script type="text/javascript" src="../styles/docfx.js"></script>
<script type="text/javascript" src="../styles/main.js"></script>
</body>
</html>