# com.bea.ide.lang.xml.driver
XmlStructureViewDriver Class

public class XmlStructureViewDriver
extends `Object`
implements `IStructureViewDriver`

Driver for Xml structure view.

Hierarchy
  `Object`
  `XmlStructureViewDriver`

All Implemented Interfaces
  `IStructureViewDriver`

## Constructor Summary

XmlStructureViewDriver(`XmlDocument` doc)

## Method Summary

`public int` | `compareName`(`IElement` el1, `IElement` el2) Compares two nodes for alphabetical sorting.
`public int` | `compareType`(`IElement` el1, `IElement` el2) Compares two nodes for group-by-type sorting.
`public `IElement`` | `getDocumentElement`(`IElement` node) Returns the element in the structure tree that should be selected when the IDocumentView's SelectedElement property is set to the given element
`public `Icon`` | `getIcon`(`IElement` el) Returns the icon for the given displayed element or null if the element has no icon.
`public `Object`` | `getPopupMenu`(`IElement` el) Returns the popup menu to display for this element or null if there is no popup.
`public `IElement`` | `getSelectionElement`(`IElement` el) Returns the element that should be set as the selected element when the given element is selected in the structure view
`public `String`` | `getTooltip`(`IElement` el) Returns the tooltip for this element or null if there is no tooltip.
`public boolean` | `isDisplayed`(`IElement` el) Determines whether the given element should be displayed at all.
`public boolean` | `isFollowed`(`ILinkedElement` el) Determines whether the data pointed to by this linked element should be followed.
`public boolean` | `isLeaf`(`IElement` el) Determines whether the given element should be a leaf (i.e. it's children should not be explored)
`public void` | `performDoubleClickAction`(`IElement` el) Perform the action that occurs on a double-click of this element

Methods from class `java.lang.`Object``
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods from interface `com.bea.ide.ui.structureview.`IStructureViewDriver``
``compareName`, `compareType`, `getDocumentElement`, `getIcon`, `getPopupMenu`, `getSelectionElement`, `getTooltip`, `isDisplayed`, `isFollowed`, `isLeaf`, `performDoubleClickAction``

## Constructor Detail

### XmlStructureViewDriver

    public XmlStructureViewDriver(XmlDocument doc)

## Method Detail

### compareName(IElement, IElement) Method

    public int compareName(IElement el1,
                           IElement el2)

Description copied from `IStructureViewDriver.compareName(IElement, IElement)`
Compares two nodes for alphabetical sorting.

### compareType(IElement, IElement) Method

    public int compareType(IElement el1,
                           IElement el2)

Description copied from `IStructureViewDriver.compareType(IElement, IElement)`
Compares two nodes for group-by-type sorting.

### getDocumentElement(IElement) Method

    public IElement getDocumentElement(IElement node)

Description copied from `IStructureViewDriver.getDocumentElement(IElement)`
Returns the element in the structure tree that should be selected when the IDocumentView's SelectedElement property is set to the given element

### getIcon(IElement) Method

    public Icon getIcon(IElement el)

Description copied from `IStructureViewDriver.getIcon(IElement)`
Returns the icon for the given displayed element or null if the element has no icon.

### getPopupMenu(IElement) Method

    public Object getPopupMenu(IElement el)

Description copied from `IStructureViewDriver.getPopupMenu(IElement)`
Returns the popup menu to display for this element or null if there is no popup. This method may return a String in which case it is taken to be the name of a popup menu declared in the ActionSvc and will be shown accordingly. Or it may retrun a javax.swing.JPopupMenu directly.

### getSelectionElement(IElement) Method

    public IElement getSelectionElement(IElement el)

Description copied from `IStructureViewDriver.getSelectionElement(IElement)`
Returns the element that should be set as the selected element when the given element is selected in the structure view

### getTooltip(IElement) Method

    public String getTooltip(IElement el)

Description copied from `IStructureViewDriver.getTooltip(IElement)`
Returns the tooltip for this element or null if there is no tooltip.

### isDisplayed(IElement) Method

    public boolean isDisplayed(IElement el)

Description copied from `IStructureViewDriver.isDisplayed(IElement)`
Determines whether the given element should be displayed at all.

### isFollowed(ILinkedElement) Method

    public boolean isFollowed(ILinkedElement el)

Description copied from `IStructureViewDriver.isFollowed(ILinkedElement)`
Determines whether the data pointed to by this linked element should be followed.

### isLeaf(IElement) Method

    public boolean isLeaf(IElement el)

Description copied from `IStructureViewDriver.isLeaf(IElement)`
Determines whether the given element should be a leaf (i.e. it's children should not be explored)

### performDoubleClickAction(IElement) Method

    public void performDoubleClickAction(IElement el)

Description copied from `IStructureViewDriver.performDoubleClickAction(IElement)`
Perform the action that occurs on a double-click of this element