[Codenarc-developer] Can GetterMethodCouldBeProperty be extended to check static getter methods as
Brought to you by:
chrismair
From: Chris M. <chr...@ea...> - 2012-01-20 02:02:46
|
If a class defines a static getter method to return a constant, that could be replaced with a static property. e.g. static String getName() { 'abc' } Could be replaced by: static (final) name = 'abc' So, I am inclined to extend GetterMethodCouldBeProperty to check for static getter methods as well. http://codenarc.sourceforge.net/codenarc-rules-groovyism.html#GetterMethodCo uldBeProperty Any objection? Chris |