org.opensourcephysics.controls
Class XMLTree

java.lang.Object
  extended byorg.opensourcephysics.controls.XMLTree

public class XMLTree
extends java.lang.Object

This is an XML tree in a scroller.


Field Summary
protected  XMLControl control
           
protected  java.lang.Class hilite
           
protected static javax.swing.Icon hiliteIcon
           
protected  XMLTreeNode root
           
protected  javax.swing.JScrollPane scroller
           
protected  java.util.List selectedProps
           
protected  javax.swing.JTree tree
           
 
Constructor Summary
XMLTree(XMLControl control)
          Contructs a tree view of an XMLControl
 
Method Summary
protected  void createGUI()
          Creates the GUI and listeners.
 java.lang.Class getHighlightedClass()
          Gets the highlighted class.
 javax.swing.JScrollPane getScrollPane()
          Gets the scroll pane with view of the tree
 java.util.List getSelectedProperties()
          Gets the selected xml properties.
 javax.swing.JTree getTree()
          Gets the tree.
 void selectHighlightedProperties()
          Selects the highlighted properties.
 void setHighlightedClass(java.lang.Class type)
          Sets the highlighted class.
 void showHighlightedProperties()
          Shows the highlighted properties.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

hiliteIcon

protected static javax.swing.Icon hiliteIcon

root

protected XMLTreeNode root

tree

protected javax.swing.JTree tree

scroller

protected javax.swing.JScrollPane scroller

control

protected XMLControl control

selectedProps

protected java.util.List selectedProps

hilite

protected java.lang.Class hilite
Constructor Detail

XMLTree

public XMLTree(XMLControl control)
Contructs a tree view of an XMLControl

Parameters:
control - the XMLControl
Method Detail

getTree

public javax.swing.JTree getTree()
Gets the tree.

Returns:
the tree

getSelectedProperties

public java.util.List getSelectedProperties()
Gets the selected xml properties.

Returns:
a list of currently selected properties

getScrollPane

public javax.swing.JScrollPane getScrollPane()
Gets the scroll pane with view of the tree

Returns:
the scroll pane

setHighlightedClass

public void setHighlightedClass(java.lang.Class type)
Sets the highlighted class.

Parameters:
type - the class to highlight

getHighlightedClass

public java.lang.Class getHighlightedClass()
Gets the highlighted class.

Returns:
the highlighted class

selectHighlightedProperties

public void selectHighlightedProperties()
Selects the highlighted properties.


showHighlightedProperties

public void showHighlightedProperties()
Shows the highlighted properties.


createGUI

protected void createGUI()
Creates the GUI and listeners.