Next | Advanced Programming Techniques | Slide #16 |
In OOP, we would make an abstract base class with a walk_tree method
walk_tree would call undefined file and dir methods
To use, we would subclass and define file and dir
The subclasses would all inherit the same walk_tree method
The functional programming technique is essentially the same
But simpler and lighter-weight
Next | Copyright © 2000 M-J. Dominus |