Skip to content
Clément Fournier edited this page May 31, 2019 · 18 revisions

Welcome to the pmd-designer wiki!

The rule designer

The rule designer is both a way to inspect the tree on which PMD rules run on, and to write XPath rules in an integrated manner. This page describes the features that enable this.

AST inspection

designer_top

You can enter source code in the middle zone.

  • Make sure to select the correct language and version for your source code with the cog icon on the top!
  • If the source is valid using this setting, the tree to the right will update to display the AST of the code
  • When selecting a node, the left panel updates with information about a node

Selecting nodes

There are several ways to focus a node for inspection:

  • From the tree view or the crumb bar: just click on an item
  • From the source code: maintain CTRL for a second until the code area becomes mostly blue. Then, each node you hover over on the code area will be selected automatically. Example:

![Ctrl-hover selection example][images/node-selection.gif]

Clone this wiki locally