@Override
    public Object @NotNull [] getChildElements(@NotNull Object element) {
      final List<Object> result = new ArrayList<>();
      collectChildren(element, result);
      final Iterator<Object> it = result.iterator();
      while (it.hasNext()) {
        if (!acceptsElement(it.next())) it.remove();
      }
      for (Object o : result) {
        myParentsMap.put(o, element);
      }
      return result.toArray();
    }
@Override
    public Object @NotNull [] getChildElements(@NotNull Object element)