Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Mail Systems
Eclipse Documentation

How To Guides
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Problem Solutions
Privacy Policy




Extending Eclipse monitoring, profiling, and testing functions
Previous Page Home Next Page

Creating the plug-in

Write a plug-in that extends the extension point org.eclipse.hyades.ui.analyzerExtensions. This adds an entry to the Open With menu. A plug-in project needs to be created to hold the demo analyzer plug-in's code. Follow these steps to create and prepare an analyzer plug-in project:

  1. Create a new plug-in project. In the New Plug-in Project wizard, enter project name org.eclipse.hyades.demo.analyzerview. Accept default settings. Click Next.
  2. Accept default settings. Click Finish.

A plug-in project with a MANIFEST.MF file and a plug-in class that extends AbstractUIPlugin has been created. Add the following required plug-ins to the new plug-in's dependencies:

  • org.eclipse.hyades.trace.ui
  • org.eclipse.emf.ecore
  • org.eclipse.tptp.platform.models

The demo analyzer plug-in will require the TPTP Trace Model plug-in, the TPTP Trace Core UI plug-in and the Eclipse JFace plug-in. To reference them in the demo analyzer plug-in, add the following three lines into the plug-in manifest <require> markup. The manifest should look like this:

Require-Bundle: org.eclipse.ui,

Extend and contribute your analyzer extension by adding the following to the plugin.xml file.

            name="Demo Analyzer View"

The four required fields are:

The analyzer's unique identification is specified in this tag.
The analyzer's name is specified in this.
The tag dictates the type of object to which this analyzer is applicable; in this case it is trace objects. Other valid values for this tag include other TPTP resources such as test suite and deployment.
This tag specifies the name of the class when an action is invoked on the Open With menu item. This class must implement org.eclipse.jface.action.IAction.

All the other fields are optional. Note the use of tag type, which associates the analyzer with a particular type of object. Other valid values for this tag are Logging, Monitor and Host. TPTP adds the option in Open With to invoke the analyzer on any given object according to the value in type. For example, when the value is Host, the analyzer will only be available on host objects in the Profiling Monitor view.

Add a folder to the plug-in project named icons and add this icon (sample.gif) to it: sample icon

The next stage is to create the class that will perform the actions for the view.

Related tasks
Adding a view to the Profiling and Logging Perspective
Add a class for the action
Add a class for the view

  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire