class GroupActivator {

    public void activateDeactivateGroup(boolean activate, DataGroupInfo dataGroupInfo, UserConfirmer confirmer)
    {
        if (confirmWithUser(activate, dataGroupInfo, confirmer))
        {
            try
            {
                // Activate self and children
                myDataGroupActivator.setGroupsActive(dataGroupInfo.groupStream().parallel(), activate);

                // Activate (grand)parents
                for (DataGroupInfo parent = dataGroupInfo.getParent(); parent != null; parent = parent.getParent())
                {
                    if (activate || canDeactivate(parent))
                    {
                        myDataGroupActivator.setGroupActive(parent, activate);
                    }
                }
            }
            catch (InterruptedException e)
            {
                LOGGER.error(e, e);
            }
        }
    }

    public  GroupActivator(DataGroupActivator activator);

}