Create an object hierarchy of functions from a directory structure