org.eclipse.ecf.presence.ui.roster
Class AbstractRosterGroupContributionItem

java.lang.Object
  extended by org.eclipse.jface.action.ContributionItem
      extended by org.eclipse.ui.actions.CompoundContributionItem
          extended by org.eclipse.ecf.presence.ui.roster.AbstractPresenceContributionItem
              extended by org.eclipse.ecf.presence.ui.roster.AbstractRosterGroupContributionItem
All Implemented Interfaces:
org.eclipse.jface.action.IContributionItem

public abstract class AbstractRosterGroupContributionItem
extends AbstractPresenceContributionItem

Abstract contribution item class for creating menu contribution items for roster entries. Subclasses should be created as appropriate.


Field Summary
 
Fields inherited from class org.eclipse.ecf.presence.ui.roster.AbstractPresenceContributionItem
EMPTY_ARRAY
 
Constructor Summary
AbstractRosterGroupContributionItem()
           
AbstractRosterGroupContributionItem(java.lang.String id)
           
 
Method Summary
protected  IContainer getContainerForRosterEntry(IRosterEntry group)
          Get container for the given IRosterGroup.
protected  IRosterGroup getSelectedRosterGroup()
          Get the currently selected IRosterGroup.
 
Methods inherited from class org.eclipse.ecf.presence.ui.roster.AbstractPresenceContributionItem
getContributionItems, getSelection, makeActions
 
Methods inherited from class org.eclipse.ui.actions.CompoundContributionItem
dispose, fill, isDirty, isDynamic, setParent
 
Methods inherited from class org.eclipse.jface.action.ContributionItem
fill, fill, fill, getId, getParent, isEnabled, isGroupMarker, isSeparator, isVisible, saveWidgetState, setId, setVisible, toString, update, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AbstractRosterGroupContributionItem

public AbstractRosterGroupContributionItem()

AbstractRosterGroupContributionItem

public AbstractRosterGroupContributionItem(java.lang.String id)
Method Detail

getSelectedRosterGroup

protected IRosterGroup getSelectedRosterGroup()
Get the currently selected IRosterGroup.

Returns:
IRosterGroup that is current workbenchwindow selection. Returns null if nothing is selected or if something other than IRosterGroup is selected.

getContainerForRosterEntry

protected IContainer getContainerForRosterEntry(IRosterEntry group)
Get container for the given IRosterGroup.

Parameters:
group - the IRosterGroup. May be null.
Returns:
IContainer associated with currently selected IRosterGroup. Returns null if the given entry is null, or if the container associated with the group cannot be accessed.