| java.lang.Object org.eclipse.ui.internal.navigator.NavigatorActivationService
NavigatorActivationService | final public class NavigatorActivationService implements INavigatorActivationService(Code) | | The activation service determines if an extension is active within the
context of a given viewer. If an extension is active then the extension
will contribute functionality to the viewer. If an extension is not active,
then the extension will not be given opportunities to contribute
functionality to the given viewer. See
INavigatorContentService for
more detail on what states are associated with a content extension.
since: 3.2 |
NavigatorActivationService | public NavigatorActivationService(INavigatorContentService aContentService)(Code) | | Create an instance of the service.
Parameters: aContentService - The associated content service. |
isNavigatorExtensionActive | public boolean isNavigatorExtensionActive(String aNavigatorExtensionId)(Code) | | Checks the known activation state for the given viewer id to determine if
the given navigator extension is 'active'.
Parameters: aNavigatorExtensionId - The unique identifier associated with a given extension. True if the extension is active in the context of the viewer id. |
persistExtensionActivations | public void persistExtensionActivations()(Code) | | Save the activation state for the given viewer.
|
setActive | public void setActive(String aNavigatorExtensionId, boolean toEnable)(Code) | | Set the activation state for the given extension in the context of the
given viewer id. Each instance of an INavigatorContentService listens for
the activation service to update; and if those instances were created
with viewers, they will issue a refresh. Otherwise, clients are
responsible for refreshing the viewers.
Clients must call
NavigatorActivationService.persistExtensionActivations() to save
the the activation state.
When clients are updating a batch of extensions, consider using
NavigatorActivationService.setActive(String[],boolean) when
possible to avoid unnecessary notifications.
Parameters: aNavigatorExtensionId - The unique identifier associated with a given extension. Parameters: toEnable - True indicates the extension should be enabled; Falseindicates otherwise. |
setActive | public void setActive(String[] aNavigatorExtensionIds, boolean toEnable)(Code) | | Set the activation state for the given extension in the context of the
given viewer id. Each instance of an INavigatorContentService listens for
the activation service to update; and if those instances were created
with viewers, they will issue a refresh. Otherwise, clients are
responsible for refreshing the viewers.
Clients must call
NavigatorActivationService.persistExtensionActivations() to save
the the activation state.
Parameters: aNavigatorExtensionIds - An array of unique identifiers associated with existingextension. Parameters: toEnable - True indicates the extension should be enabled; Falseindicates otherwise. |
|
|