public interface GeneratedMetaMethod.ProxyFactory
Creates the generated DGM adapter for a DgmMethodRecord by its index, with a direct constructor call rather than reflection.
The one implementation, org.codehaus.groovy.runtime.DgmProxyFactory,
is generated by DgmConverter alongside the adapters themselves, so
that the adapters are reachable through ordinary static analysis (GraalVM
native image needs no reflection metadata for them) and their first use
costs a switch and a constructor call rather than a class lookup and a
reflective instantiation. That class registers itself with
Proxy.register when it is initialised.
DgmProxyFactoryConfig switches the factory off in favour of
the reflective path.
| Type Params | Return Type | Name and description |
|---|---|---|
|
public MetaMethod |
create(int index, String name, CachedClass declaringClass, Class returnType, Class[] parameters)
|
index, or null
if the index is out of range