Hi
I am trying to delete nodes of a Tree but I am getting ArrayIndexOutOfBoundsException. While debugging I am seeing that the nodes are getting deleted properly and they are not displayed in Tree but I get these exceptions. Please refer to stack trace below and help me in resolving this issue
Exception in thread "AWT-EventQueue-0" java.lang.ArrayIndexOutOfBoundsException:
0 >= 0
at java.util.Vector.elementAt(Unknown Source)
at javax.swing.tree.DefaultMutableTreeNode.getChildAt(Unknown Source)
at javax.swing.tree.VariableHeightLayoutCache.treeNodesRemoved(Unknown S
ource)
at javax.swing.plaf.basic.BasicTreeUI$Handler.treeNodesRemoved(Unknown S
ource)
at com.sun.javatest.exec.TestTreeModel$Notifier.run(TestTreeModel.java:1
490)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Exception in thread "AWT-EventQueue-0" Exception in thread "AWT-EventQueue-0" Ex
ception in thread "AWT-EventQueue-0" java.lang.ArrayIndexOutOfBoundsException: 0
>= 0
at java.util.Vector.elementAt(Unknown Source)
at javax.swing.tree.DefaultMutableTreeNode.getChildAt(Unknown Source)
at javax.swing.tree.VariableHeightLayoutCache.treeNodesRemoved(Unknown S
ource)
at javax.swing.plaf.basic.BasicTreeUI$Handler.treeNodesRemoved(Unknown S
ource)
at com.sun.javatest.exec.TestTreeModel$Notifier.run(TestTreeModel.java:1
490)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
java.lang.ArrayIndexOutOfBoundsException: 0 >= 0
at java.util.Vector.elementAt(Unknown Source)
at javax.swing.tree.DefaultMutableTreeNode.getChildAt(Unknown Source)
at javax.swing.tree.VariableHeightLayoutCache.treeNodesRemoved(Unknown S
ource)
at javax.swing.plaf.basic.BasicTreeUI$Handler.treeNodesRemoved(Unknown S
ource)
at com.sun.javatest.exec.TestTreeModel$Notifier.run(TestTreeModel.java:1
490)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
java.lang.ArrayIndexOutOfBoundsException: 0 >= 0
at java.util.Vector.elementAt(Unknown Source)
at javax.swing.tree.DefaultMutableTreeNode.getChildAt(Unknown Source)
at javax.swing.tree.VariableHeightLayoutCache.treeNodesRemoved(Unknown S
ource)
at javax.swing.plaf.basic.BasicTreeUI$Handler.treeNodesRemoved(Unknown S
ource)
at com.sun.javatest.exec.TestTreeModel$Notifier.run(TestTreeModel.java:1
490)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)