I was very cool what can be done:
class Foo { String name } def foo = new Foo(name:"Test")
But this only works when the file name matches the class name. If I have a file with a bunch of classes like:
class AllClassesInOneFile { class Bar {} class Foo { String name } } def foo = new Foo(name:"Test")
Now it no longer works. I get java.lang.IllegalArgumentException: wrong number of arguments
I wonder if it is possible to call the argument style of the parameter name using scripts and nested classes.
Hello
source share