|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JPanel ix.util.xml.XMLTreeEditPanel
public class XMLTreeEditPanel
A panel that contains an XML tree-editor.
XMLTreeEditor
,
XMLTreeEditFrame
,
Serialized FormNested Class Summary | |
---|---|
(package private) class |
XMLTreeEditPanel.CutFrame
A frame that shows a subtree cut from the main editor panel. |
(package private) class |
XMLTreeEditPanel.EditingTextArea
A text area for editing string values |
(package private) class |
XMLTreeEditPanel.EditorTree
JTree subclass used for all trees in the editor. |
(package private) class |
XMLTreeEditPanel.InvalidCommand
|
(package private) class |
XMLTreeEditPanel.InvalidNode
|
(package private) class |
XMLTreeEditPanel.NodePopupMenu
The default class of popup menu that appears when the user does a right-button press on a tree node. |
(package private) class |
XMLTreeEditPanel.ObjTNode
A TNode in the namespace used for object class and field names. |
(package private) class |
XMLTreeEditPanel.RecordingExpansionListener
A TreeExpansionListener that records whether a node should be expanded or not. |
(package private) class |
XMLTreeEditPanel.TemplateSyntax
Knows about the syntax of Java classes. |
(package private) class |
XMLTreeEditPanel.TemplateTree
A tree variety used for templates |
(package private) class |
XMLTreeEditPanel.TNode
A TreeNode for use in EditorTrees. |
(package private) class |
XMLTreeEditPanel.TNodeFactory
Makes XMLTreeEditPanel.TNode s from JDOM Documents and Elements. |
(package private) class |
XMLTreeEditPanel.TNodeParser
Responsible for understanding the object-like structure of tree nodes and for converting nodes into JDOM Documents or Elements. |
(package private) class |
XMLTreeEditPanel.TNodeRenderer
A renderer that knows about namespaces. |
(package private) class |
XMLTreeEditPanel.TreeMouseListener
|
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
javax.swing.JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
javax.swing.JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
java.awt.Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary | |
---|---|
protected static java.lang.String |
ATTRIBUTES
|
protected javax.swing.tree.DefaultTreeModel |
docModel
|
protected javax.swing.JSplitPane |
docSplit
|
protected XMLTreeEditPanel.EditorTree |
docTree
|
protected org.jdom.Document |
document
The document this panel is editing. |
protected XMLTreeEditPanel.EditingTextArea |
editText
|
protected static XMLTreeEditPanel.EditorTree |
mostRecentlySelectedTree
|
protected XMLTreeEditPanel.TNodeFactory |
nodeFactory
|
protected XMLTreeEditPanel.TNodeParser |
nodeParser
|
protected javax.swing.JButton |
submitButton
|
protected XMLTreeEditPanel.TemplateSyntax |
syntax
|
protected XMLTreeEditPanel.EditorTree |
templateTree
|
protected javax.swing.JSplitPane |
textSplit
|
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
XMLTreeEditPanel()
|
Method Summary | |
---|---|
void |
actionPerformed(java.awt.event.ActionEvent e)
Action interpreter for panel buttons |
void |
addChild()
Adds a new node after the existing children of the selected node. |
void |
addRootChild(org.jdom.Document doc)
|
void |
addTemplate(XMLTreeEditPanel.TNode template)
|
void |
addTemplates()
|
void |
addTemplatesFor(java.lang.Class[] classes)
|
protected void |
complain(java.lang.Object message)
|
void |
copySubtree()
Copy the subtree below and including the currently selected node. |
void |
cutSubtree()
"Cut" the subtree below and including the currently selected node. |
void |
editDocument(org.jdom.Document doc)
|
void |
editObject(java.lang.Object object)
|
void |
expandDocument(int depth)
|
void |
findInTree(java.lang.String targetText)
Finds text in the most recently selected tree even if the tree is not in this panel. |
org.jdom.Document |
getDocument()
|
protected XMLTreeEditFrame |
getEditFrame()
|
protected java.awt.Color |
getNamespaceColor(org.jdom.Namespace n)
|
java.lang.Object |
getObject()
|
void |
hideTemplates()
|
protected javax.swing.JButton |
makeButton(java.lang.String command)
|
protected javax.swing.JPanel |
makeButtonPanel()
|
(package private) javax.swing.JPopupMenu |
makeNodePopupMenu(XMLTreeEditPanel.EditorTree tree,
XMLTreeEditPanel.TNode node)
Factory method that makes a popup menu for right-press on a tree node. |
protected XMLTreeEditPanel.EditorTree |
makeTemplateTree()
|
void |
namespaceEvent(NamespaceEvent e)
Something has happened, releted to the source Namespace. |
protected void |
noteNamespace(org.jdom.Namespace n)
|
protected void |
reset()
|
protected void |
setDocRoot(XMLTreeEditPanel.TNode root)
|
(package private) void |
setSelectedTree(XMLTreeEditPanel.EditorTree tree)
|
void |
valueChanged(javax.swing.event.TreeSelectionEvent e)
Required by the TreeSelectionListener interface. |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
Methods inherited from class javax.swing.JComponent |
---|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
Methods inherited from class java.awt.Container |
---|
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree |
Methods inherited from class java.awt.Component |
---|
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected org.jdom.Document document
protected static final java.lang.String ATTRIBUTES
protected static XMLTreeEditPanel.EditorTree mostRecentlySelectedTree
protected XMLTreeEditPanel.TNodeFactory nodeFactory
protected XMLTreeEditPanel.TNodeParser nodeParser
protected XMLTreeEditPanel.TemplateSyntax syntax
protected XMLTreeEditPanel.EditorTree docTree
protected javax.swing.tree.DefaultTreeModel docModel
protected XMLTreeEditPanel.EditorTree templateTree
protected XMLTreeEditPanel.EditingTextArea editText
protected javax.swing.JButton submitButton
protected javax.swing.JSplitPane docSplit
protected javax.swing.JSplitPane textSplit
Constructor Detail |
---|
public XMLTreeEditPanel()
Method Detail |
---|
protected void reset()
protected XMLTreeEditFrame getEditFrame()
protected void setDocRoot(XMLTreeEditPanel.TNode root)
public void editDocument(org.jdom.Document doc)
public org.jdom.Document getDocument()
public void expandDocument(int depth)
public void addRootChild(org.jdom.Document doc)
public void editObject(java.lang.Object object)
public java.lang.Object getObject()
public void findInTree(java.lang.String targetText)
protected java.awt.Color getNamespaceColor(org.jdom.Namespace n)
protected void noteNamespace(org.jdom.Namespace n)
public void namespaceEvent(NamespaceEvent e)
NamespaceListener
namespaceEvent
in interface NamespaceListener
public void addTemplates()
public void addTemplatesFor(java.lang.Class[] classes)
public void addTemplate(XMLTreeEditPanel.TNode template)
public void hideTemplates()
protected XMLTreeEditPanel.EditorTree makeTemplateTree()
protected javax.swing.JPanel makeButtonPanel()
protected javax.swing.JButton makeButton(java.lang.String command)
public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed
in interface java.awt.event.ActionListener
public void addChild()
public void copySubtree()
public void cutSubtree()
protected void complain(java.lang.Object message)
public void valueChanged(javax.swing.event.TreeSelectionEvent e)
valueChanged
in interface javax.swing.event.TreeSelectionListener
void setSelectedTree(XMLTreeEditPanel.EditorTree tree)
javax.swing.JPopupMenu makeNodePopupMenu(XMLTreeEditPanel.EditorTree tree, XMLTreeEditPanel.TNode node)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |