Refactor config class

Move options parsing off the constructor to make it more readable.