Iterable<Module> (Module module) { final Iterator<Module> iterator = myState.forwardDirection ? myModuleGraph.getIn(module) : myModuleGraph.getOut(module); return new Iterable<>() { @Override public Iterator<Module> iterator() { return iterator; } }; }