Open peteruhnak opened 8 years ago
Hi. There is already RBSubclassResponsibilityNotDefinedRule
. But I think that the validation should be shifted to the class that is missing concrete implementations. There is already an autofix, but using refactoring may be more sense. I'll give it a try, thanks :)
Having it in the subclass sounds more sensible. It's not the parent's fault that the children don't obey. :)
(I am not sure if suggestions for new rules should go here or to fogzbugz; I can move it if needed…)
A new rule that would warn me if I didn't override an abstract method.
An abstract method contains
self subclassResponsibility
.The "autofix" option could use
RBRealizeClassRefactoring
to automatically create stubs for the abstract methods. (This is what is used by right click on class → Refactoring → class refactoring → realize)