summaryrefslogtreecommitdiff
path: root/src/SMAPI/Framework/Patching/IHarmonyPatch.cs
blob: 922243fa597ba5e6e484d662df4bf5701896b62e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#if HARMONY_2
using HarmonyLib;
#else
using Harmony;
#endif

namespace StardewModdingAPI.Framework.Patching
{
    /// <summary>A Harmony patch to apply.</summary>
    internal interface IHarmonyPatch
    {
        /// <summary>A unique name for this patch.</summary>
        string Name { get; }

        /// <summary>Apply the Harmony patch.</summary>
        /// <param name="harmony">The Harmony instance.</param>
#if HARMONY_2
        void Apply(Harmony harmony);
#else
        void Apply(HarmonyInstance harmony);
#endif
    }
}