Generate OpaqueObject implementation
With the advent of CodecClassLoader we can safely instantiate
codec-specific implementations of binding interfaces instead
of relying on dynamic proxies.
This has several advantages:
- we do not generate a proxy class in public space, hence our mess
will undergo normal GC rules
- generated code is a normal final class, hence we can inherit
method implementations from interfaces and subclasses
- for each instance, we do not require a proxy and an invocation
handler, so we instantiate only one object
- there is no reflection in the invocation path, hence JIT has
full (and direct) visibility and can perform all of its magic
This patch does that for OpaqueObject, which results extremely
simple generated classes: they just subclass a ForeignOpaqueObject
and add the target binding interface.
JIRA: MDSAL-442
Change-Id: I2be5bb88f9557375f517415d6bec9f68e803628c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>