Show / Hide Table of Contents

Class HarmonyMethodExtensions

Annotation extensions

Inheritance
object
HarmonyMethodExtensions
Namespace: HarmonyLib
Assembly: 0Harmony.dll
Syntax
public static class HarmonyMethodExtensions

Methods

Clone(HarmonyMethod)

Clones an annotation

Declaration
public static HarmonyMethod Clone(this HarmonyMethod original)
Parameters
Type Name Description
HarmonyMethod original

The HarmonyMethod to clone

Returns
Type Description
HarmonyMethod

A copied HarmonyMethod

CopyTo(HarmonyMethod, HarmonyMethod)

Copies annotation information

Declaration
public static void CopyTo(this HarmonyMethod from, HarmonyMethod to)
Parameters
Type Name Description
HarmonyMethod from

The source HarmonyMethod

HarmonyMethod to

The destination HarmonyMethod

GetFromMethod(MethodBase)

Gets all annotations on a method

Declaration
public static List<HarmonyMethod> GetFromMethod(MethodBase method)
Parameters
Type Name Description
MethodBase method

The method/constructor

Returns
Type Description
List<HarmonyMethod>

A list of HarmonyMethod

GetFromType(Type)

Gets all annotations on a class/type

Declaration
public static List<HarmonyMethod> GetFromType(Type type)
Parameters
Type Name Description
Type type

The class/type

Returns
Type Description
List<HarmonyMethod>

A list of all HarmonyMethod

GetMergedFromMethod(MethodBase)

Gets merged annotations on a method

Declaration
public static HarmonyMethod GetMergedFromMethod(MethodBase method)
Parameters
Type Name Description
MethodBase method

The method/constructor

Returns
Type Description
HarmonyMethod

The merged HarmonyMethod

GetMergedFromType(Type)

Gets merged annotations on a class/type

Declaration
public static HarmonyMethod GetMergedFromType(Type type)
Parameters
Type Name Description
Type type

The class/type

Returns
Type Description
HarmonyMethod

The merged HarmonyMethod

Merge(HarmonyMethod, HarmonyMethod)

Merges annotations

Declaration
public static HarmonyMethod Merge(this HarmonyMethod master, HarmonyMethod detail)
Parameters
Type Name Description
HarmonyMethod master

The master HarmonyMethod

HarmonyMethod detail

The detail HarmonyMethod

Returns
Type Description
HarmonyMethod

A new, merged HarmonyMethod

In this article
Back to top Generated by DocFX