| java.lang.Object org.netbeans.modules.xml.refactoring.spi.UIHelper
UIHelper | public class UIHelper (Code) | | Default UI Helper.
author: Nam Nguyen |
Method Summary | |
public Node | getDisplayNode(Component component) Returns specific node for displaying the component in a preview window.
The Node should return the following information that will be used
in the refactoring UI:
getActions(boolean) -
other Actions for the Component, preferably navigational actions
Minimally, getActions() should return a Go To Source Action, which
will open the source (text) view with the cursor at the Component line
The Actions should also implement org.openide.util.actions.Presenter.
When the action is invoked from a prefuse graph node,
actionPerformed(ActionEvent) is called with the Component as the source
in the ActionEvent.
getDisplayName() -
a String that will be used as the label on the Component's explorer and
graph nodes.
getHtmlDisplayName() -
For the usage component, a one line code snippet with the name
of the query component bolded. | public Node | getDisplayNode(Model model) | public List<Component> | getRelevantPathFromRoot(Component component) Return UI relevant path from root. |
getDisplayNode | public Node getDisplayNode(Component component)(Code) | | Returns specific node for displaying the component in a preview window.
The Node should return the following information that will be used
in the refactoring UI:
getActions(boolean) -
other Actions for the Component, preferably navigational actions
Minimally, getActions() should return a Go To Source Action, which
will open the source (text) view with the cursor at the Component line
The Actions should also implement org.openide.util.actions.Presenter.
When the action is invoked from a prefuse graph node,
actionPerformed(ActionEvent) is called with the Component as the source
in the ActionEvent.
getDisplayName() -
a String that will be used as the label on the Component's explorer and
graph nodes.
getHtmlDisplayName() -
For the usage component, a one line code snippet with the name
of the query component bolded. The Html display name is used in the
Find Usages explorer and the refactoring preview explorer on the
usage node.
The string should be formatted to use < and > for
the XML tags, and < and > for the HTML tags. In the following example,
Find Usages was run on a schema global type named "POSLogCurrencyCode".
The Node represents a schema local element that uses POSLogCurrencyCode.
getHtmlDisplayName() returns the first line of the local element.
The text "POSLogCurrencyCode" in the snippet will be bolded because it is
the name of the query Component.
<xs:element name="CurrencyCode" type="POSLogCurrencyCode" minOccurs="0"/>
getIcon() -
an Image for the icon on the Components explorer and graph nodes.
getPreferredAction() -
the Action which navigates to the primary view of the Component
|
getDisplayNode | public Node getDisplayNode(Model model)(Code) | | |
getRelevantPathFromRoot | public List<Component> getRelevantPathFromRoot(Component component)(Code) | | Return UI relevant path from root. Specific implementation should
override.
|
|
|