@ SuppressWarnings ( "unchecked" ) public static < T > Class < T > classForName ( String className ) { try { return ( Class < T > ) Class . forName ( className ) ; } catch ( ClassNotFoundException | VerifyError e ) { // Catching VerifyError fixes issue #147. I don't know how to unit test it. return null ; } }
Helper method to resolve a Class of a given name .