private Collection<NodeSubscription> getSubscriptions(Node child) {
        Collection<NodeSubscription> subscriptions = new ArrayList<>();
        for (NodeSubscription subscription : getSubscriptions()) {
            if (subscription.canSendChildNodeEvent(child)) {
                subscriptions.add(subscription);
            }
        }
        Log.trace("Got {} subscription(s) for child node '{}'.", subscriptions.size(), child.getNodeID());
        return subscriptions;
    }
Returns a collection with the subscriptions to this node that should be notified
that a new child was added or deleted.

@param child the added or deleted child.
@return a collection with the subscriptions to this node that should be notified
        that a new child was added or deleted.
xmppserver/src/main/java/org/jivesoftware/openfire/pubsub/CollectionNode.java