public ReachableMethods(CallGraph graph, Iterator<? extends MethodOrMethodContext> entryPoints, Filter filter) { this.filter = filter; this.cg = graph; addMethods(entryPoints); unprocessedMethods = reachables.reader(); this.edgeSource = graph.listener(); if (filter != null) { this.edgeSource = filter.wrap(this.edgeSource); } }
/** * Causes the QueueReader objects to be filled up with any methods that have become reachable since the last call. */ public void update() { while (edgeSource.hasNext()) { Edge e = edgeSource.next(); if (set.contains(e.getSrc())) { addMethod(e.getTgt()); } } while (unprocessedMethods.hasNext()) { MethodOrMethodContext m = unprocessedMethods.next(); Iterator<Edge> targets = cg.edgesOutOf(m); if (filter != null) { targets = filter.wrap(targets); } addMethods(new Targets(targets)); } }
public ReachableMethods( CallGraph graph, Iterator<MethodOrMethodContext> entryPoints, Filter filter ) { this.filter = filter; this.cg = graph; addMethods( entryPoints ); unprocessedMethods = reachables.reader(); this.edgeSource = graph.listener(); if( filter != null ) this.edgeSource = filter.wrap( this.edgeSource ); } public ReachableMethods( CallGraph graph, Collection<MethodOrMethodContext> entryPoints ) {
public ReachableMethods( CallGraph graph, Iterator<MethodOrMethodContext> entryPoints, Filter filter ) { this.filter = filter; this.cg = graph; addMethods( entryPoints ); unprocessedMethods = reachables.reader(); this.edgeSource = graph.listener(); if( filter != null ) this.edgeSource = filter.wrap( this.edgeSource ); } public ReachableMethods( CallGraph graph, Collection<MethodOrMethodContext> entryPoints ) {
/** Causes the QueueReader objects to be filled up with any methods * that have become reachable since the last call. */ public void update() { while(edgeSource.hasNext()) { Edge e = (Edge) edgeSource.next(); if( set.contains( e.getSrc() ) ) addMethod( e.getTgt() ); } while(unprocessedMethods.hasNext()) { MethodOrMethodContext m = (MethodOrMethodContext) unprocessedMethods.next(); Iterator<Edge> targets = cg.edgesOutOf( m ); if( filter != null ) targets = filter.wrap( targets ); addMethods( new Targets( targets ) ); } } /** Returns a QueueReader object containing all methods found reachable
/** Causes the QueueReader objects to be filled up with any methods * that have become reachable since the last call. */ public void update() { while(edgeSource.hasNext()) { Edge e = (Edge) edgeSource.next(); if( set.contains( e.getSrc() ) ) addMethod( e.getTgt() ); } while(unprocessedMethods.hasNext()) { MethodOrMethodContext m = (MethodOrMethodContext) unprocessedMethods.next(); Iterator<Edge> targets = cg.edgesOutOf( m ); if( filter != null ) targets = filter.wrap( targets ); addMethods( new Targets( targets ) ); } } /** Returns a QueueReader object containing all methods found reachable