void (@NotNull DefaultMutableTreeNode node) { @SuppressWarnings({"unchecked", "rawtypes"}) Enumeration<DefaultMutableTreeNode> children = (Enumeration)node.children(); for (DefaultMutableTreeNode child : Collections.list(children)) { disposeNode(child); } node.removeAllChildren(); nodeStructureChanged(node); }