@Override
  public @NotNull Collection<StructureViewExtension> getAllExtensions(@NotNull Class<? extends PsiElement> type) {
    Collection<StructureViewExtension> result = myImplExtensions.get(type);
    if (result != null) {
      return result;
    }

    ExtensionPointImpl<@NotNull StructureViewExtension> point = (ExtensionPointImpl<@NotNull StructureViewExtension>)EXTENSION_POINT_NAME.getPoint();
    Set<Class<? extends PsiElement>> visitedTypes = new HashSet<>();
    result = new ArrayList<>();
    for (StructureViewExtension extension : point.getExtensionList()) {
      Class<? extends PsiElement> registeredType = extension.getType();
      if (ReflectionUtil.isAssignable(registeredType, type) && visitedTypes.add(registeredType)) {
        result.addAll(ExtensionProcessingHelper.INSTANCE.getByGroupingKey(point, StructureViewExtension.class, registeredType, StructureViewExtension::getType));
      }
    }

    Collection<StructureViewExtension> oldValue = myImplExtensions.putIfAbsent(type, result);
    return oldValue == null ? result : oldValue;
  }
@Override
  public @NotNull Collection<StructureViewExtension> getAllExtensions(@NotNull Class<? extends PsiElement> type)