refactoring the command line parsing into its own class instead of main()