Skip to main content

Notice: This Wiki is now read only and edits are no longer possible. Please see: for the plan.

Jump to: navigation, search

PTP/ETFw/PTP External Tools Framework Feedback View


ETFw Feedback view

EclipseCon 2010 presentation on the Feedback view


The Parallel Tools Platform External Tools Framework Feedback view provides an eclipse view, exposing information found e.g. in an XML file, with convenient mapping and navigation to source lines referenced in the XML file. For example, a compiler or analysis tool may expose items of interest in an XML file and list the filename and line number (or range of lines, or character region) applicable to the item found. A performance tool may note regions of interest with source code lines that are referenced.

The PTP ETFw Feedback view allows a convenient way to expose this information in a way that allows the user to easily navigate to the source code lines in the user's source code.

While this is included in PTP Release 3.0, these APIs should be considered "pre-release" quality (provisionary) and could change. Please email if you are using them, to join in the discussion of possible changes. I will attempt to not break anything you are actually using.

Show Items in feedback view

Note that the ETFw Feedback view code that is part of PTP (since Release 3.0) does not include a concrete view that shows ETFw Feedback view capabilities. It is a framework that makes constructing this easier. However, an example is provided to show some of the features that are available.

As an example, to see how to construct a plug-in like this, check out the project from CVS as follows (scroll to the bottom if you just want to try it)

  • Host:
  • Repository path: /cvsroot/tools
  • Under HEAD, scroll down to org.eclipse.ptp and expand it.
  • Expand tools/etfw
  • Check out

Launch a development eclipse workspace with the project and the project. Then:

  1. Create a basic C project (or almost any type of Eclipse project will do)
  2. Put the xml file in the project (e.g. use data/sample.xml from the sample project)
  3. Put source files referenced in the xml file(s) in the same directory (e.g. use data/sample.c from the above project) as the xml file, unless you put specific code in your plug-in to find them.
  4. Select the xml file in the Project Explorer view. Hit the ETFw Feedback view button in the toolbar (See green arrow in image below. Hover says "Show Feedback View for selected XML File")
  5. The xml file is parsed by the SampleFeedbackParser class, IFeedbackItems are created, and markers are created for each of these, which appear in the Feedback view. Green arrow points to Feedback View at bottom of Eclipse workbench window.
    • The items are initially all collapsed. You can expand individual parent nodes, or use the "Expand All" button in the view's toolbar (see red arrow in the sample image below) to see more information.
  6. To see the source file line referred to by an item, double-click on the line in the "Sample Feedback items" view.
  7. To see more information on an item, rightMouse and select "Show Info", or select the item and hit the "Show Info" (icon "i") button in the view toolbar.

Installing and running the Feedback view sample

For SC10 tutorial

  • Now we need to find some sample code to run with it. Three alternatives with a decreasing amount of "tinkering" required:
    • If you have the Eclipse PDE (Plugins Development Environment) - e.g. if your eclipse download started with "Eclipse classic"
      • You can "take part" the plugin
      • Window > Show View > Other... Plu-in Development > Plug-ins
      • In the Plugins view, find, rightmouse on it and Import as > Source project
      • Back in the Project Explorer view you will see the new project
      • Expand the project and its 'data' folder - the sample.c and sample.xml files are what you need
      • (Optional: copy these two files to a local C project - or just use them right here)
      • select the sample.xml file in the Project Explorer then hit the feedback button Feedback view.gif in the toolbar
    • If you don't have the Eclipse PDE, we can "take apart" the plugin by hand to get at its hidden treasures
      • Unzip the jar file to find the data folder
      • copy the sample.c and sample.xml to a local C project
      • select the sample.xml file in the Project Explorer then hit the feedback button Feedback view.gif in the toolbar
    • Just give me those two files please!

Copyright © Eclipse Foundation, Inc. All Rights Reserved.