docs/api/HarmonyLib.HarmonyMethodExtensions.html
Annotation extensions
System.Object
HarmonyMethodExtensions
public static class HarmonyMethodExtensions
Clones an annotation
public static HarmonyMethod Clone(this HarmonyMethod original)
| Type | Name | Description |
|---|---|---|
| HarmonyMethod | original |
The HarmonyMethod to clone
|
| Type | Description |
|---|---|
| HarmonyMethod |
A copied HarmonyMethod
|
Copies annotation information
public static void CopyTo(this HarmonyMethod from, HarmonyMethod to)
| Type | Name | Description |
|---|---|---|
| HarmonyMethod | from |
The source HarmonyMethod
| | HarmonyMethod | to |
The destination HarmonyMethod
|
Gets all annotations on a method
public static List<HarmonyMethod> GetFromMethod(MethodBase method)
| Type | Name | Description |
|---|---|---|
| System.Reflection.MethodBase | method |
The method/constructor
|
| Type | Description |
|---|---|
| System.Collections.Generic.List<HarmonyMethod> |
A list of HarmonyMethod
|
Gets all annotations on a class/type
public static List<HarmonyMethod> GetFromType(Type type)
| Type | Name | Description |
|---|---|---|
| System.Type | type |
The class/type
|
| Type | Description |
|---|---|
| System.Collections.Generic.List<HarmonyMethod> |
A list of all HarmonyMethod
|
Gets merged annotations on a method
public static HarmonyMethod GetMergedFromMethod(MethodBase method)
| Type | Name | Description |
|---|---|---|
| System.Reflection.MethodBase | method |
The method/constructor
|
| Type | Description |
|---|---|
| HarmonyMethod |
The merged HarmonyMethod
|
Gets merged annotations on a class/type
public static HarmonyMethod GetMergedFromType(Type type)
| Type | Name | Description |
|---|---|---|
| System.Type | type |
The class/type
|
| Type | Description |
|---|---|
| HarmonyMethod |
The merged HarmonyMethod
|
Merges annotations
public static HarmonyMethod Merge(this HarmonyMethod master, HarmonyMethod detail)
| Type | Name | Description |
|---|---|---|
| HarmonyMethod | master |
The master HarmonyMethod
| | HarmonyMethod | detail |
The detail HarmonyMethod
|
| Type | Description |
|---|---|
| HarmonyMethod |
A new, merged HarmonyMethod
|