Lab 4 En

1. Say our company wants to develop a new operating system. It wants it to support the file system and Drivers. A program for this operating system can work with the file system, can be a driver, or can do both. It should be easy to add new programs.

One of the most important classes in the system, widely used by a lot of programs and other components is the File class, which contains a dependency on the Content class.

All programs of the operating system should implement the Program interface.

There is also program, called SimpleLS, that is written by a coworker that is on holiday. Your job is to refactor the SimpleLS program and the entire framework until your coworkers return from holiday 2 weeks from now.

The most important requirements are:

  • the framework should not contain duplication
  • it should be easy to add new programs
  • it should be easy to add new File types
  • it should be easy to add new File permissions
  • it should be possible to sell features independently, as plugins (ex: you should be able to add a file permission and/or file type through a paid plugin).

Given that the operating system is still in its incipient state, you are allowed to modify any of the files/classes.

Happy coding! :)