Search in sources :

Example 1 with GroupAboutToBeDestroyedEvent

use of org.cytoscape.group.events.GroupAboutToBeDestroyedEvent in project cytoscape-impl by cytoscape.

the class CyGroupManagerImpl method destroyGroup.

@Override
public void destroyGroup(CyGroup group) {
    synchronized (lock) {
        if (!groupSet.contains(group))
            return;
    }
    final CyEventHelper cyEventHelper = getService(CyEventHelper.class);
    cyEventHelper.fireEvent(new GroupAboutToBeDestroyedEvent(CyGroupManagerImpl.this, group));
    synchronized (lock) {
        if (rootMap.containsKey(group.getRootNetwork()))
            rootMap.get(group.getRootNetwork()).remove(group);
        groupSet.remove(group);
    }
    ((CyGroupImpl) group).destroyGroup();
// updateGroupAttribute(group);
}
Also used : GroupAboutToBeDestroyedEvent(org.cytoscape.group.events.GroupAboutToBeDestroyedEvent) CyEventHelper(org.cytoscape.event.CyEventHelper)

Aggregations

CyEventHelper (org.cytoscape.event.CyEventHelper)1 GroupAboutToBeDestroyedEvent (org.cytoscape.group.events.GroupAboutToBeDestroyedEvent)1