Is there a way to implement this template in a general way?
The dispatcher object and the set of work objects come from the same interface.
Any method call to the dispatcher object must be sent (redirected) to one of the working objects (with all arguments).
Each method will need to open its own name, find the corresponding method in the work objects, find the arguments, and then make a call. If possible, do not use the variable argument mechanism.
Is there any way to do this? Reflection? Code generation?
reflection c #
Ziffusion
source share