Programming For Reuse
The common opinion is that "reuse is dead". This is because
I'll try to analyze the situation and give a simple solution to the problem.
- promises of reuse often failed in the past
- reuse doesn't pay in the short run and therefore
- few people are really interested in reuse
|What is reuse?|
Reuse means to use prefabricated code and data structures out of the box. Often code and data structures are combined into modules or objects so creating somewhat bigger ReuseUnits?. The spectrum of packaging ReuseUnits? starts with small libraries and ends in monolythic runtime environments. ReuseUnits? may either become integral parts of executable programs or stay within shared libraries or runtime environments being used by numerous simultanously running applications.
|What are the elements of reuse?|
- modules (objects and data structures, functions and methods)
|What is needed for reuse?|
To create an programming environment where reuse can happen you need
The libraries usually do exist as part of the operating system, the programming language or the hardware interfaces. They must exist, because otherwise the systems would not be usable.
- low cost of reuse
The quality of the libraries is usually low with respect to reuse. They do create working interfaces, but most APIs are inconsistent and therefore difficult to learn, to remember and to use. There is no general idea (or accepted theory) of API quality.
Stability exists in certain areas (OS, language standards), but mainly in the form that producers try to avoid to break existing and working software.