Generate Getters and Setters does not show any fields to select from Follow
Hi,
In our project we have adopted this coding style to prefix all member variables with an underscore. So I have this field named _project. Now when I press Alt+Insert to generate getters and setters for the _project variable, IDEA does not show any of the fields so that I can select from as it can be seen in the provided screenshot. Is this a bug or am I missing something?
Thanks in advance,
Behrang
Attachment(s):
Generate GetSet.PNG
Please sign in to leave a comment.
Hello Behrang,
_project is a final field, so it can't have a setter, so it isn't shown in
"Generate getters and setters" dialog. The name of the field doesn't matter.
--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"
Duh... makes sense! I was in a semi-dumb state yesterday...