private static boolean hasMethod ( JavaClass c , Method candidateMethod ) { String name = candidateMethod . getName ( ) ; String sig = candidateMethod . getSignature ( ) ; for ( Method method : c . getMethods ( ) ) { if ( ! method . isStatic ( ) && method . getName ( ) . equals ( name ) && method . getSignature ( ) . equals ( sig ) ) { return true ; } } return false ; }
looks to see if a class has a method with a specific name and signature