Refactor of the code and creation of .jar