What is Code Generation?

Reuse of existing components
   Not at the binary level (OO, libraries, Java...)
   ... but at the source code level

Common: ad-hoc code generators
   Source code templates are built-in
   Completely specific to one task

Rare: schema-driven code generator
   Source code templates are external 'schemas'
   Still usually dedicated to one task