source code generation:option generate getter/setter and constructor (#1594)

a properly defined class requires at least one constructor, and usually a gettor and setter by attribute

it is therefore normal that the generated code generates them too (which is not the case for now .....)

it is therefore necessary that these three elements be proposed during the generation of the source code

8 April 2019 21:49:01
29 January 2020 20:43:35
Requested by
windows 10 x64
Solved in

Dusan Rodina - 9 April 2019 21:22:50

Support for generation of constructors will be added soon. Getters and setters may be added in two ways:

1) Add «property» stereotype to an attribute

2) Right click on an attribute and choose Add Getter and Setter - it will add the getter and setter operation to your class

fr016 14 April 2019 21:18:07


one more thing

the current generation of getter and setter starts with a capital letter which is not the case in practice

here a correct sample in Java:

this is also the case in many languages such as C# or php

would it be possible to correct that too?

thank you

Dusan Rodina - 14 April 2019 22:23:23

Actually, Pascal Case (the first letter capital) is used for method names in C# and VB.NET. So this feature will have to be made language specific. It will be implemented in one of next versions.

fr016 16 April 2019 16:55:00

Ok thx

Your Name:
You can use these formatting tags: [b]bold[/b] [i]italic[/i] [u]underline[/u] [url][/url] [code]some code[/code] [quote]quoted text[/quote] [list]one list item per line[/list]