Moved parseFile() to a new Java class