Implements http://jira.sonarsource.com/browse/RSPEC-1182 and replaces http://jira.sonarsource.com/browse/RSPEC-255 and http://jira.sonarsource.com/browse/RSPEC-433 and http://jira.sonarsource.com/browse/RSPEC-1183 and http://jira.sonarsource.com/browse/RSPEC-330
Manually tested !
@Dinesh, I'm reopening this ticket as this rule also replaces PMD "Clone method must implement Cloneable" http://jira.sonarsource.com/browse/RSPEC-329
@Freddy It is not clear to me if we only need to add the depreciation link, or if the behavior of the rule must be updated.
It seems in this case that behavior has been updated.
Well afterall it seems that there's just a depreciation link missing.
But I don't really get it, because AFAIK, we don't cover PMD's CloneMethodMustImplementCloneable rule with this one.
Done, but check my previous comment Freddy please.
If a class has a clone() method which comply with this rule "super.clone() method should be called when overriding the Object.clone() method", as a side effect the class MUST implement the Cloneable interface otherwise a CloneNotSupportedException will be thrown by the root Object.clone() method. qed !