File monitoring

Refactored FileMonitoring classes.
Edited comments of the FileMonitoring functionality.
Added unit test for the FileMonitoring functionality.
Refactored unit test for removing repeated logic.