Class ByteBuddyPatch

java.lang.Object
me.tamkungz.nilkit.tooling.bytebuddy.ByteBuddyPatch

public final class ByteBuddyPatch extends Object
Immutable, composable Byte Buddy patch definition.

This is deliberately closer to a Mixin configuration than to raw Byte Buddy: one target matcher owns an ordered list of mutations. Multiple patches can target the same class and are composed by ByteBuddyPatchRegistry.

  • Method Details

    • getId

      public String getId()
    • getPriority

      public int getPriority()
    • matches

      public boolean matches(net.bytebuddy.description.type.TypeDescription type)
    • apply

      public net.bytebuddy.dynamic.DynamicType.Builder<?> apply(net.bytebuddy.description.type.TypeDescription type, net.bytebuddy.dynamic.DynamicType.Builder<?> builder)
    • builder

      public static ByteBuddyPatch.Builder builder(String id, net.bytebuddy.matcher.ElementMatcher<? super net.bytebuddy.description.type.TypeDescription> typeMatcher)
    • forClass

      public static ByteBuddyPatch.Builder forClass(String id, String binaryClassName)