boolean isAssociatedWith(@NotNull T type, @NotNull FileNameMatcher matcher) {
    if (matcher instanceof ExtensionFileNameMatcher || matcher instanceof ExactFileNameMatcher) {
      return type.equals(findAssociatedFileType(matcher));
    }

    for (Pair<FileNameMatcher, T> mapping : myMatchingMappings) {
      if (matcher.equals(mapping.getFirst()) && type.equals(mapping.getSecond())) return true;
    }

    return false;
  }
boolean isAssociatedWith(@NotNull T type, @NotNull FileNameMatcher matcher)