@Override
  public boolean contains(@NotNull VirtualFile file) {
    var modules = new HashSet<>(getModulesByFile(file));
    if (modules.isEmpty() && file.getFileSystem() instanceof ArchiveFileSystem) {
      VirtualFile archiveFile = ((ArchiveFileSystem)file.getFileSystem()).getLocalByEntry(file);
      if (archiveFile != null) modules = new HashSet<>(getModulesByFile(archiveFile));
    }
    // It's possible that the file is located under some module which doesn't belong to this group,
    // but its content root is located under one of the modules that do belong to this group.
    // So we also need to check the modules that the file's modules' content roots belong to.
    addParentContentRootModules(modules);
    List<String> thisGroupPath = getValue().getGroupPathList();
    ModuleGrouper grouper = ModuleGrouper.instanceFor(getProject());
    for (Module module : modules) {
      if (ContainerUtil.startsWith(grouper.getGroupPath(module), thisGroupPath)) {
        return true;
      }
    }
    return false;
  }
@Override
  public boolean contains(@NotNull VirtualFile file)