Convert FlagUtilsTest from groovy to java
Tidy generics in FlagUtils
Refactor FlagUtils.setConfig()