public void execute ( ) throws CFGBuilderException { JavaClass jclass = classContext . getJavaClass ( ) ; Method [ ] methods = jclass . getMethods ( ) ; LOG . debug ( "Class has {} methods" , methods . length ) ; // Add call graph nodes for all methods for ( Method method : methods ) { callGraph . addNode ( method ) ; } LOG . debug ( "Added {} nodes to graph" , callGraph . getNumVertices ( ) ) ; // Scan methods for self calls for ( Method method : methods ) { MethodGen mg = classContext . getMethodGen ( method ) ; if ( mg == null ) { continue ; } scan ( callGraph . getNodeForMethod ( method ) ) ; } LOG . debug ( "Found {} self calls" , callGraph . getNumEdges ( ) ) ; }
Find the self calls .