Replies: 4 comments
-
After further research, One remaining hurdle is how to pass the source method name to the target. When using |
Beta Was this translation helpful? Give feedback.
-
I think you can add |
Beta Was this translation helpful? Give feedback.
-
@raphw I thought I had already added the |
Beta Was this translation helpful? Give feedback.
-
@raphw Indeed, the @RuntimeType annotation does the trick. Thank you. |
Beta Was this translation helpful? Give feedback.
-
UPDATE: The problem has been simplified to providing the source method name to the target of
MethodCall
(see comment below)UPDATE 2: I have reverted to trying to use
MethodDelegation
instead ofMethodCall
. Moreover, using@Pipe
annotation seems to make a difference. See thevehicle2
package in the project. It looks like I have found a working solution to my problem.Hello,
I am trying to put in place support for API extensions via user defined interfaces.
The source code for the problem at hand can be found at https://github.com/ceki/vehicle
Running the VehicleMain results in a
IllegalArgumentException
(see below).However, the
IllegalArgumentException
disappears if the return type of generate method inTigthenBoltsGenerator
is changed from<E extends Engine>
toUserDefinedEngine
.How can I convince ByteBuddy that the generate method is compatible with
ch.qos.vehicle.UserDefinedEngine.tightenBolts()
even if the return values do not match exactly?Here is the exception:
Can you point me in the right direction please?
Beta Was this translation helpful? Give feedback.
All reactions