void (@NotNull HierarchyTreeStructure treeStructure, @Nullable Element rootElement, @Nullable Comparator<? super NodeDescriptor<?>> comparator) { HierarchyNodeDescriptor rootNodeDescriptor = (HierarchyNodeDescriptor)treeStructure.getRootElement(); rootNodeDescriptor.update(); if (rootElement == null || !NODE_ELEMENT_NAME.equals(rootElement.getName())) { throw new IllegalArgumentException("Incorrect root element in verification resource"); } checkNodeDescriptorRecursively(treeStructure, rootNodeDescriptor, rootElement, comparator); }