@Override
      public @NotNull Map<String, Void> map(@NotNull FileContent inputData,
                                            @NotNull Collection<Pair<ElementPattern<FileContent>, String>> pairs) {
        Map<String, Void> result = null;
        for (Pair<ElementPattern<FileContent>, String> pair : pairs) {
          ElementPattern<FileContent> pattern = pair.getFirst();
          String detectorId = pair.getSecond();
          boolean accepts;
          try {
            accepts = pattern.accepts(inputData);
          } catch (Exception e) {
            if (e instanceof ControlFlowException) throw e;
            FrameworkDetector frameworkDetector = FrameworkDetectorRegistry.getInstance().getDetectorById(detectorId);
            throw new MapReduceIndexMappingException(e, frameworkDetector != null ? frameworkDetector.getClass() : null);
          }
          if (accepts) {
            if (LOG.isDebugEnabled()) {
              LOG.debug(inputData.getFile() + " accepted by detector " + detectorId);
            }
            if (result == null) {
              result = new HashMap<>();
            }
            myDispatcher.getMulticaster().fileUpdated(inputData.getFile(), detectorId);
            result.put(detectorId, null);
          }
        }
        return result != null ? result : Collections.emptyMap();
      }
@Override
      public @NotNull Map<String, Void> map(@NotNull FileContent inputData,
                                            @NotNull Collection<Pair<ElementPattern<FileContent>, String>> pairs)