@Override
    public boolean isDescendantNode(Node child) {
        if (isChildNode(child)) {
            return true;
        }
        for (Node node : getNodes()) {
            if (node.isDescendantNode(child)) {
                return true;
            }
        }
        return false;
    }
Returns true if the specified node is a direct child node of this collection node or
a descendant of the children nodes.

@param child the node to check if it is a descendant of this node.
@return true if the specified node is a direct child node of this collection node or
        a descendant of the children nodes.
xmppserver/src/main/java/org/jivesoftware/openfire/pubsub/CollectionNode.java