Clean up ControllerGenerator and extends it to FileGenerator class