The AdapterFabric
constructor can also take a class loader as a parameter. When none is provided,
the current thread context class loader is being used as a parent for an AdapterFabric
-internal
classloader. There is also a static method withParentClassLoader(classloader)
to obtain a fabric
whose class loader is based on a provided parent.
As it is often the case for dynamic languages on the JVM, overloaded methods with the same name but
different methods are painful. In such cases, we suggest that you take advantage of
star-implementations or star-overrides as illustrated above on a ArrayList
subclass where the 2
add(obj)
and add(index, obj)
methods are being intercepted.
Finally we do not encourage you to use adapters as part of Golo code outside of providing bridges to third-party APIs.