Author Topic: Improve Java getters and setters generation  (Read 2372 times)

WardB

  • EA Novice
  • *
  • Posts: 5
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Improve Java getters and setters generation
« on: February 13, 2006, 08:01:13 am »
Hello,

When you add an attribute in a class diagram, it's posible to mark it as a propertie of a class and let the getter and setter be automatically generated.
But these automatically generated getters and setters do not follow the JavaBean naming convention.
The JavaBean convention for getters and setters is:
getPropertie
setPropertie

but NOT:
getpropertie
setpropertie

So the first letter of an attributename should be capitalized and not a lowercase letter.

My suggestion is to improve this.

Ward

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8085
  • Karma: +118/-20
    • View Profile
Re: Improve Java getters and setters generation
« Reply #1 on: February 13, 2006, 12:51:09 pm »
Go to Tools | Options | Source Code Engineering and check 'Capitalize Attribute Name for Properties'