@ VisibleForTesting static Method getMethod ( Class < ? > cls , String name , Class < ? > ... params ) { Method m ; try { m = cls . getDeclaredMethod ( name , params ) ; } catch ( Exception e ) { throw new RuntimeException ( e ) ; } m . setAccessible ( true ) ; return m ; }
Bundle reflection calls to get access to the given method