org.netbeans.spi.navigator/1 1.2.22

org.netbeans.spi.navigator
Interface NavigatorPanel


public interface NavigatorPanel

Navigation related view description. Implementors of this interface, also registered in layer, will be plugged into Navigator UI.


Method Summary
 JComponent getComponent()
          JComponent representation of this view.
 String getDisplayHint()
          Description of the view, explaining main purpose of the view.
 String getDisplayName()
          Name of the view which will be shown in navigator UI.
 Lookup getLookup()
          Returns Lookup that will be integrated into Lookup of Navigator UI TopComponent.
 void panelActivated(Lookup context)
          Called when this panel's component is about to being displayed.
 void panelDeactivated()
          Called when this panel's component is about to being hidden.
 

Method Detail

getDisplayName

String getDisplayName()
Name of the view which will be shown in navigator UI.

Returns:
Displayable name of the view

getDisplayHint

String getDisplayHint()
Description of the view, explaining main purpose of the view. Will be shown in Navigator UI.

Returns:
String description of the view.

getComponent

JComponent getComponent()
JComponent representation of this view. System will ask multiple times and it is strongly recommended to return the same JComponent instance each call for performance reasons.

This method is always called in event dispatch thread.

Returns:
JComponent representation of this view.

panelActivated

void panelActivated(Lookup context)
Called when this panel's component is about to being displayed. Right place to attach listeners to current navigation data context, as clients are responsible for listening to context changes when active (in the time between panelActivated - panelDeactivated calls). This method is always called in event dispatch thread.

Parameters:
context - Lookup instance representing current context to take data from

panelDeactivated

void panelDeactivated()
Called when this panel's component is about to being hidden. Right place to detach, remove listeners from data context, that were added in panelActivated impl. This method is always called in event dispatch thread.


getLookup

Lookup getLookup()
Returns Lookup that will be integrated into Lookup of Navigator UI TopComponent. Allows clients for example to specify activated Node of Navigator UI TopComponent when this panel is active.

Method may return null, signalizing that default mechanism should be enabled. Default mechanism chooses first Node from Utilities.actionsGlobalContext() as activated Node for Navigator's TopComponent.

Returns:
Lookup instance or null

org.netbeans.spi.navigator/1 1.2.22

Built on July 11 2007.  |  Portions Copyright 1997-2005 Sun Microsystems, Inc. All rights reserved.