Codegen - Java - setter with return

Hi all,

i would like to use setter with return in java (Fluent interface), but codegen creates only void method. Is it possible to implement this request to the new version, such as one parameter?

Now is the instantiation of a lot of wearing. I’d like to write for example …

new User().setFirstName("").setLastName("").setEmail("");

Thank you for considering the idea

Is this avery common patterning Java — to have 'property" setters return the base object again? this is the first time i see something like this, none of the Java APIs i’m familiar with have that (and it would break how other JVM languages, such as our own Oxygene, merge getters/setters into cohesive real properties, too).

There is a description of this method, a lot of people use this …

[http://en.wikipedia.org/wiki/Fluent_interface][1] [1]: http://en.wikipedia.org/wiki/Fluent_interface

Another variant is created for each class of its own builder as shown there …

[http://runnable.com/Uvbmi7Dm2bQHAAAu/how-to-implement-fluent-interface-in-java][2] [2]: http://runnable.com/Uvbmi7Dm2bQHAAAu/how-to-implement-fluent-interface-in-java

These builders I can write it myself, but for every change in the structure of RODL file, I’ll have to change everything twice in two places. Codegen could do it automatically :wink: