@NotNull
  public static Map<DebuggerSession, Map<String, HotSwapFile>> scanForModifiedClasses(@NotNull List<DebuggerSession> sessions,
                                                                                      @Nullable NotNullLazyValue<? extends List<String>> outputPaths,
                                                                                      @NotNull HotSwapProgress swapProgress) {
    final Map<DebuggerSession, Map<String, HotSwapFile>> modifiedClasses = new HashMap<>();
    final MultiProcessCommand scanClassesCommand = new MultiProcessCommand();
    swapProgress.setCancelWorker(() -> scanClassesCommand.cancel());
    for (DebuggerSession debuggerSession : sessions) {
      if (!debuggerSession.isAttached()) {
        continue;
      }

      scanClassesCommand.addCommand(debuggerSession.getProcess(), new DebuggerCommandImpl() {
        @Override
        protected void action() {
          swapProgress.setDebuggerSession(debuggerSession);
          Map<String, HotSwapFile> sessionClasses =
            getInstance(swapProgress.getProject()).scanForModifiedClasses(debuggerSession, outputPaths, swapProgress);
          if (!sessionClasses.isEmpty()) {
            modifiedClasses.put(debuggerSession, sessionClasses);
          }
        }
      });
    }

    swapProgress.setTitle(JavaDebuggerBundle.message("progress.hotswap.scanning.classes"));
    scanClassesCommand.run();

    if (swapProgress.isCancelled()) {
      for (DebuggerSession session : sessions) {
        session.setModifiedClassesScanRequired(true);
      }
      return Collections.emptyMap();
    }
    else {
      return modifiedClasses;
    }
  }
@NotNull
  public static Map<DebuggerSession, Map<String, HotSwapFile>> scanForModifiedClasses(@NotNull List<DebuggerSession> sessions,
                                                                                      @Nullable NotNullLazyValue<? extends List<String>> outputPaths,
                                                                                      @NotNull HotSwapProgress swapProgress)