Refactored calculation of the binary path to a separate class. Also more code refactoring.