Show / Hide Table of Contents

Class PatchClassProcessor

A PatchClassProcessor used to turn HarmonyAttribute on a class/type into patches

Inheritance
System.Object
PatchClassProcessor
Namespace: HarmonyLib
Assembly: 0Harmony.dll
Syntax
public class PatchClassProcessor

Constructors

| Improve this Doc View Source

PatchClassProcessor(Harmony, Type)

Creates a patch class processor by pointing out a class. Similar to PatchAll() but without searching through all classes.

Declaration
public PatchClassProcessor(Harmony instance, Type type)
Parameters
Type Name Description
Harmony instance

The Harmony instance

System.Type type

The class to process (need to have at least a [HarmonyPatch] attribute)

Properties

| Improve this Doc View Source

Category

Name of the patch class's category

Declaration
public string Category { get; set; }
Property Value
Type Description
System.String

Methods

| Improve this Doc View Source

Patch()

Applies the patches

Declaration
public List<MethodInfo> Patch()
Returns
Type Description
System.Collections.Generic.List<System.Reflection.MethodInfo>

A list of all created replacement methods or null if patch class is not annotated

| Improve this Doc View Source

Unpatch()

REmoves the patches

Declaration
public void Unpatch()
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX