The “primitives” templates implement the entire database. Nothing is read or written if not through them. These implement just a small number of data structures. These rest on an abstract memory model, implemented in the “memory” types. In test cases we implement memory as a data chunk, in production we implement it using operating system file mapping. The “database” classes organize the templates and memory model into specific files each representing a complex data structure.