Menu

#451 false +: AbstractClassWithoutAbstractMethod ext abstr class

open
nobody
pmd (543)
5
2012-10-07
2006-02-26
Jeff Jensen
No

A declared abstract class that extends an abstract
class and has no ancestor abstract methods implemented
in it falsely triggers the
AbstractClassWithoutAbstractMethod rule.

If the declared abstract class instead implements an
interface and implements none of the interface methods,
the rule works correctly (does not trigger a false
positive).

Attached are very simple Java classes that reproduce
the false positive.

Discussion

  • Jeff Jensen

    Jeff Jensen - 2006-02-26

    Abstract classes that cause the false positive and show the interface case does not.

     
  • Jeff Jensen

    Jeff Jensen - 2006-02-26

    Logged In: YES
    user_id=498804

    Contradicts bug #1265474 (also by me), as it said interface
    case has false positive too.

     
  • Tom Copeland

    Tom Copeland - 2006-11-16

    Logged In: YES
    user_id=5159
    Originator: NO

    Assigning away from me in case someone else can look into this...
    Tom

     

Log in to post a comment.