3

I have been using Google CodePro Audit for java for few days now and i'm amazed in how much it helped me improve my code.

There are some rules which never crossed my mind and some that i don't really understand the consequences.

For instance, i always though that using utility methods were a good pratice. But there is a rule in there which states "Utility methods should be avoided except under certain circumstances" . Can anyone elaborate on that ?

Also, post your opinions in which are the MUST rules to follow using codePro.

Thank You. Regards Bruno

ehanoc
  • 2,187
  • 18
  • 23
  • I ran a deadcode anaylsis on my Android project today only to find it didnt seem to fully support Androids method of using Intents to access code. Gave a lot of false positives, presumably because of this... – Kurru Aug 24 '11 at 19:26

1 Answers1

0

I think the reason for the warning is that utility methods take away from the Object Oriented nature of Java programming.

However, I don't think I've ever worked on a Java project that didn't have at least one utility class containing only public static methods.

CrackerJack9
  • 3,650
  • 1
  • 27
  • 48