diff options
author | Jesse Plamondon-Willard <github@jplamondonw.com> | 2017-02-09 13:45:34 -0500 |
---|---|---|
committer | Jesse Plamondon-Willard <github@jplamondonw.com> | 2017-02-09 13:45:34 -0500 |
commit | 40a90147420614d7d593b478fcf93b9be542c5b0 (patch) | |
tree | 4719a5c5d7a6fc6813ba32dac3e54af4b623de03 /src/StardewModdingAPI.AssemblyRewriters/IMethodRewriter.cs | |
parent | 036595cc712d20e7c0fb9a9a9444d5206a25ad7e (diff) | |
download | SMAPI-40a90147420614d7d593b478fcf93b9be542c5b0.tar.gz SMAPI-40a90147420614d7d593b478fcf93b9be542c5b0.tar.bz2 SMAPI-40a90147420614d7d593b478fcf93b9be542c5b0.zip |
generalise CIL rewriters for reuse (#231)
Diffstat (limited to 'src/StardewModdingAPI.AssemblyRewriters/IMethodRewriter.cs')
-rw-r--r-- | src/StardewModdingAPI.AssemblyRewriters/IMethodRewriter.cs | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/src/StardewModdingAPI.AssemblyRewriters/IMethodRewriter.cs b/src/StardewModdingAPI.AssemblyRewriters/IMethodRewriter.cs deleted file mode 100644 index 5cbb7e0d..00000000 --- a/src/StardewModdingAPI.AssemblyRewriters/IMethodRewriter.cs +++ /dev/null @@ -1,21 +0,0 @@ -using Mono.Cecil; -using Mono.Cecil.Cil; - -namespace StardewModdingAPI.AssemblyRewriters -{ - /// <summary>Rewrites a method for compatibility.</summary> - public interface IMethodRewriter - { - /// <summary>Get whether the given method reference can be rewritten.</summary> - /// <param name="methodRef">The method reference.</param> - bool ShouldRewrite(MethodReference methodRef); - - /// <summary>Rewrite a method for compatibility.</summary> - /// <param name="module">The module being rewritten.</param> - /// <param name="cil">The CIL rewriter.</param> - /// <param name="callOp">The instruction which calls the method.</param> - /// <param name="methodRef">The method reference invoked by the <paramref name="callOp"/>.</param> - /// <param name="assemblyMap">Metadata for mapping assemblies to the current platform.</param> - void Rewrite(ModuleDefinition module, ILProcessor cil, Instruction callOp, MethodReference methodRef, PlatformAssemblyMap assemblyMap); - } -} |