Working with the Custom Content Provider Extension sample
This sample demonstrates how to extend the content provider to display additional file types in the
Profiling Monitor Navigator of the Profiling and Logging Perspective.
If you have not already done so, create the example by selecting File > New >
Example... > Custom Content Provider Sample.
The sample contains the following elements which allow a new file type to be displayed in the Navigator:
- plugin.xml:
Contains the extension point, org.eclipse.tptp.platform.common.ui.pdCustomContentProvider, for the custom content provider.
- org.eclipse.tptp.content.provider.sample.Activator:
The default plug-in Activator for the project.
- org.eclipse.tptp.content.provider.sample.HTMLContentProvider:
This is an implementation of org.eclipse.hyades.ui.provisional.extension.ICustomContentProvider for the custom content
provider extension to determine items viewable in the Navigator.
- org.eclipse.tptp.content.provider.sample.HTMLNavItem:
This class implements org.eclipse.hyades.ui.extension.INavigatorItem to create an item that can be displayed in the Navigator.
The following procedure outlines the steps needed to view the contributions to the TPTP Profiling Monitor Navigator of the
Profiling and Logging Perspective for files containing an html file extension made by this sample extension:
- Launch an instance of a runtime workbench by selecting Run > Run As > Eclipse Application.
- Create a new Project by selecting File > New > Project... > General > Project and entering a name for
the Project.
- Create a new File in the Project by selecting File > New > File, choosing the project created in the previous step
for the destination and a file name ending with the .html file extension.
- Open the Profiling and Logging Perspective, switch to the Monitoring Navigator if it is not already open, and verify the
newly created file is viewable.
(C) Copyright IBM Corporation 2010. All Rights Reserved.