There is an idiom in groovy to implement an Interface with a single closure. The closure must be prepared to handle whatever arguments are passed. That works fine. But how does one determine what method was called at the interface?
interface X
{ void f(); void g(int n); void h(String s, int n); }
x = {Object[] args -> println "method called with $args"} as X
x.f()
The args are available but that name of the method that was called is - apparently - not. Am I missing something?