Model review and simulation > Reviewer > Provided PTC reviews > Style reviews > Abstract class not used as a data type (Reviewer Review)
Abstract class not used as a data type (Reviewer Review)
If a class is abstract with no operations or only has abstract operations then it can bring value to a model through its polymorphism.
This review reports these abstract classes that are not being used as:
parameter data type
operation return type
attribute
navigable association.
Consequences
This may result in a lost opportunity for re-use by making operations/attributes/associations (through collections) use the more general class.
Sometimes too many abstract classes can be the result of over-designing or over-analyzing a solution.
Sometimes abstract classes provide a single point to define common attributes or characteristics of a class (especially during analysis) and there are no functional reasons to use the base class.
Strategy
Consider whether the abstract base class can be used in cases where the concrete class is being used, and change the model accordingly.
Ignore the review comment explaining why the class adds value to the model.