Table of Contents

Class PatchJob

Namespace
MonkeyLoader.Patching
Assembly
MonkeyLoader.dll

Contains all the information for an EarlyMonkey<TMonkey>'s patching work while tracking changes.

public sealed class PatchJob
Inheritance
PatchJob
Inherited Members

Properties

Assembly

Gets or sets the AssemblyDefinition that was targeted.
Automatically sets Changes = true when replacing the definition.

public AssemblyDefinition Assembly { get; set; }

Property Value

AssemblyDefinition

Changes

Gets or sets whether any changes were made.

public bool Changes { get; set; }

Property Value

bool

Error

Gets whether this patch job failed hard (i.e. threw an Exception).
When this is true, Failed will be as well.

public bool Error { get; }

Property Value

bool

Failed

Gets whether this patch job failed (softly).

public bool Failed { get; }

Property Value

bool

this[string]

Efficiently gets the TypeDefinition for the given full name.

public TypeDefinition this[string fullName] { get; }

Parameters

fullName string

The full name of the type to get.

Property Value

TypeDefinition

The type's definition.

Exceptions

KeyNotFoundException

If the type's definition wasn't found.

Target

Gets the PrePatchTarget this PatchJob was created for.

public PrePatchTarget Target { get; }

Property Value

PrePatchTarget

Types

Gets the TypeDefinitions for the types specified in the target.

public IEnumerable<TypeDefinition> Types { get; }

Property Value

IEnumerable<TypeDefinition>

Methods

TryGetTypeDefinition(string, out TypeDefinition?)

Efficiently tries to get the TypeDefinition for the given full name.

public bool TryGetTypeDefinition(string fullName, out TypeDefinition? typeDefinition)

Parameters

fullName string

The full name of the type to get.

typeDefinition TypeDefinition

The type's definition, or null if it couldn't be found.

Returns

bool

Whether the type's definition was found.