Hitachi Vantara Pentaho Community Wiki
Child pages
  • PDI Spoon Plugin Development

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin

...

Attached to this wiki is a zip file containing an example Spoon Plugin, some of which you'll see below. In addition to a simple Hello World example, it also contains a more complex document-based Spoon Perspective.

Below is a current list of areas written in XUL that can be modified:

  • Menu system
  • Toolbars
  • Agile BI
  • Database Explorer Dialog

Current Spoon Plugin Doc:

Developing Spoon Perspectives

Common Use Cases

The most common use case is to add new functionality to Spoon. However, user interface elements can be hidden, rearranged or have their behaviors changed by Spoon Plugins.

...

Code Block
titleSample Annotated Class
<?xml version='1.0' encoding='UTF-8'?>
@SpoonPlugin(id = "SpoonExample", image = "")
@SpoonPluginCategories({"spoon"})
public class HelloWorldSpoonPlugin implements SpoonPluginInterface {
....
}

...

Code Block
titleExample modifying the menusystem of spoon
  public void applyToContainer(String category, XulDomContainer container) throws XulException {
    container.registerClassLoader(getClass().getClassLoader());
    if(category.equals("spoon")){
      container.loadOverlay("org/pentaho/di/plugins/examples/helloworld/res/spoon_overlay.xul");
      container.addEventHandler(new HelloWorldPerspectiveHandler());
    }
  }

Plugin Area

Category ID

Spoon Menusystem and toolbar

"spoon"

Database Explorer Dialog

"database_dialog"

Job Toolbar

"job-graph"

Transformation Toolbar

"trans-graph"

Repository Explorer

"repository-explorer"

Providing New Prespectives to Spoon

...