boolean (@NotNull Object pathComponent, @NotNull TreeNode thisComponent) { while (pathComponent != thisComponent && thisComponent != null) thisComponent = thisComponent.getParent(); return thisComponent != null; }