remove Scan class and update File clas with unit test