feat!: seal abstract class Patch as an interface

This commit is contained in:
oSumAtrIX
2022-10-04 08:26:26 +02:00
parent 8c502448be
commit 4d581811db
6 changed files with 24 additions and 32 deletions

View File

@@ -13,7 +13,7 @@ import app.revanced.patcher.patch.PatchResult
import app.revanced.patcher.patch.PatchResultSuccess
import app.revanced.patcher.patch.annotations.DependsOn
import app.revanced.patcher.patch.annotations.Patch
import app.revanced.patcher.patch.impl.BytecodePatch
import app.revanced.patcher.patch.BytecodePatch
import app.revanced.patcher.usage.resource.annotation.ExampleResourceCompatibility
import app.revanced.patcher.util.proxy.mutableTypes.MutableField.Companion.toMutable
import app.revanced.patcher.util.proxy.mutableTypes.MutableMethod.Companion.toMutable

View File

@@ -7,7 +7,7 @@ import app.revanced.patcher.data.impl.ResourceData
import app.revanced.patcher.patch.PatchResult
import app.revanced.patcher.patch.PatchResultSuccess
import app.revanced.patcher.patch.annotations.Patch
import app.revanced.patcher.patch.impl.ResourcePatch
import app.revanced.patcher.patch.ResourcePatch
import app.revanced.patcher.usage.resource.annotation.ExampleResourceCompatibility
import org.w3c.dom.Element
@@ -16,7 +16,7 @@ import org.w3c.dom.Element
@Description("Example demonstration of a resource patch.")
@ExampleResourceCompatibility
@Version("0.0.1")
class ExampleResourcePatch : ResourcePatch() {
class ExampleResourcePatch : ResourcePatch {
override fun execute(data: ResourceData): PatchResult {
data.xmlEditor["AndroidManifest.xml"].use { editor ->
val element = editor // regular DomFileEditor