Did you consider adding one more level of abstraction with the `case`s, depending on which shared functions a `case` needs? 

You could end up with `base_case`, `file_case`, and `index_case`, which would give us declarations like `class existing_file(file_case)`, `class case_directory_no_index_file(index_case)`, and `class case_directory_index_file(file_case, index_case)`, and segue that into something light about inheritance and composition.

That may get either too complex or too out of scope, but if it worked I think it would be an instructive example.