Subclassing the TextClass

  1. editing of depths for DIVs
  2. specific searching
  3. specific filtering

Example:

Assume that there is a subroutine/method called TextFilter in the superclass TextClass.pm that does basic filtering of large portions of text. It could do "generic" filtering and then call another method named CollSpecificTextFilter. In the TextClass superclass the CollSpecificTextFilter is an empty subroutine (essentially an abstract method).

In any subclass of TextClass, the CollSpecificTextFilter could be filled in to do specific, other filtering.

Any object that is an instantiation of the generic TextClass will get nothing more than the generic filtering, even after the empty CollSpecificTextFilter routine is called.

Any object that is an instantiation of a subclass of TextClass will get the generic filtering (of its superclass's TextFilter method) plus the CollSpecificTextFilter inside the subclass.