Package net.sf.cglib.proxy
Class BridgeMethodResolver
- java.lang.Object
-
- net.sf.cglib.proxy.BridgeMethodResolver
-
class BridgeMethodResolver extends java.lang.Object
Uses bytecode reflection to figure out the targets of all bridge methods that use invokespecial and invokeinterface, so that we can later rewrite them to use invokevirtual.For interface bridges, using invokesuper will fail since the method being bridged to is in a superinterface, not a superclass. Starting in Java 8, javac emits default bridge methods in interfaces, which use invokeinterface to bridge to the target method.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static class
BridgeMethodResolver.BridgedFinder
-
Field Summary
Fields Modifier and Type Field Description private java.lang.ClassLoader
classLoader
private java.util.Map
declToBridge
-
Constructor Summary
Constructors Constructor Description BridgeMethodResolver(java.util.Map declToBridge, java.lang.ClassLoader classLoader)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Map
resolveAll()
Finds all bridge methods that are being called with invokespecial & returns them.
-