Bug 250198 [CommonNavigator] Allow CommonNavigator to be subclassed
I believe CommonNavigator.java should be subclassable. I'm not sure why it is not intended to be subclassed. Many of the individual components ARE intended to be subclassed. I've read many many bugs where users are subclassing CommonNavigator anyway, to get around other bugs or deficiencies. I think this ability to subclass is valuable and important. I'm attaching a patch to allow for easier subclassing of the CommonNavigator class. By adding a protected getMemento() method, an adopter can override both the createCommonViewer and createCommonManager methods. By changing getLinkHelperService() to protected, the user can better override the createCommonActionGroup method with a subclass implementation of the CommonNavigatorActionGroup class. These slight changes would make the CommonNavigator class much easier to override in bits and pieces. I think it is important. Currently, CommonViewer *is* allowed to be subclassed, but to create a Common Navigator with just a slight tiny change to CommonViewer, I'd need to copy the entire CommonNavigator class because createCommonViewer() includes the line: aViewer.getNavigatorContentService().restoreState(memento); which requires access to the memento, which is private. Again, these tiny changes would make subclassing much easier without ruining anything.
bundles/org.eclipse.ui.navigator/src/org/eclipse/ui/navigator/CommonNavigator.java
* @return Whether linking the current selection with open editors is
	 *         enabled.
	 */
	public final boolean isLinkingEnabled() {
		return isLinkingEnabled;
	}
	/**
	 * <p>
	 * Provides access to the commonViewer used by the current CommonNavigator.
	 * The field will not be valid until after
	 * {@link #init(IViewSite, IMemento)}&nbsp;has been called by the
	 * Workbench.
	 * </p>
	 *  
	 * @return The (already created) instance of Common Viewer.
	 */
	public CommonViewer getCommonViewer() {
		return commonViewer;
	}
	/**
	 * @return The Navigator Content Service which populates this instance of
	 *         Common Navigator
	 */
	public INavigatorContentService getNavigatorContentService() {
		return getCommonViewer().getNavigatorContentService();
	}
	/**
	 * Returns an object which is an instance of the given class
	 * associated with this object. Returns <code>null</code> if
	 * no such object can be found.