Feature-Oriented ProgrammingThe term for a kind of metaprogramming.
Excerpt from Getting Started below:
Feature Oriented Programming (FOP) is the the study of feature modularity, where features are raised to first-class entities in design. Features are implemented by cross-cuts that are modifications or extensions to multiple classes. Unlike AOP aspects, whose focus is on quantification -- i.e., specifying predicates that identify join points at which to insert code -- feature implementations are actually much closer to OO framework designs. That is, to add a feature to an OO framework, there are predefined methods and classes that are to be extended. In such designs, there is little or no quantification, but there are indeed "cross-cuts". This is the approach that we have used for years in building program families (aka product lines).
Algebraic Hierarchical Equations for Application Design (AHEAD) is an example of FOP. It is a simple and general algebraic model of program synthesis that is based on step-wise refinement -- a methodology that advocates that complex systems can be built by adding features incrementally. FOP and AHEAD address a fundamental problem in software engineering -- a path to its future.
The future of software engineering is in automation. The best practical example of automated software engineering is relational query optimization. That is, database queries are expressed using a declarative specification (SQL) that is mapped to an efficient program. The general problem of mapping from a declarative spec to a provably efficient program is very difficult -- it is called automatic programming). The success of relational databases rests on relational algebra -- a set of fundamental operators on tables -- and that query evaluation programs are expressions -- compositions of relational algebra operators. Optimizers use algebraic identities to rewrite, and hence optimize, expressions, which in turn optimizes query evaluation programs. This is how databases "solve" the automatic programming problem for query evaluation programs.