@ Override public void visitMethod ( Method obj ) { methodSignatureIsConstrained = false ; String methodName = obj . getName ( ) ; if ( ! Values . CONSTRUCTOR . equals ( methodName ) && ! Values . STATIC_INITIALIZER . equals ( methodName ) ) { String methodSig = obj . getSignature ( ) ; methodSignatureIsConstrained = methodIsSpecial ( methodName , methodSig ) || methodHasSyntheticTwin ( methodName , methodSig ) ; if ( ! methodSignatureIsConstrained ) { for ( AnnotationEntry entry : obj . getAnnotationEntries ( ) ) { if ( CONVERSION_ANNOTATIONS . contains ( entry . getAnnotationType ( ) ) ) { methodSignatureIsConstrained = true ; break ; } } } if ( ! methodSignatureIsConstrained ) { String parms = methodSig . split ( "\\(|\\)" ) [ 1 ] ; if ( parms . indexOf ( Values . SIG_QUALIFIED_CLASS_SUFFIX_CHAR ) >= 0 ) { outer : for ( JavaClass constrainCls : constrainingClasses ) { Method [ ] methods = constrainCls . getMethods ( ) ; for ( Method m : methods ) { if ( methodName . equals ( m . getName ( ) ) && methodSig . equals ( m . getSignature ( ) ) ) { methodSignatureIsConstrained = true ; break outer ; } } } } } } }
implements the visitor to look to see if this method is constrained by a superclass or interface .