java.lang.ClassCastException: eu.matim.editor.sandbox.jtree.FileSelectorModel cannot be cast to javax.swing.tree.DefaultTreeModel

Coderanch | Mathew Mintalm | 6 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    JTree refresh, with new TreeModel

    Coderanch | 6 years ago | Mathew Mintalm
    java.lang.ClassCastException: eu.matim.editor.sandbox.jtree.FileSelectorModel cannot be cast to javax.swing.tree.DefaultTreeModel

    Root Cause Analysis

    1. java.lang.ClassCastException

      eu.matim.editor.sandbox.jtree.FileSelectorModel cannot be cast to javax.swing.tree.DefaultTreeModel

      at eu.matim.editor.sandbox.jtree.FilePreviewer$4.actionPerformed()
    2. eu.matim.editor
      FilePreviewer$4.actionPerformed
      1. eu.matim.editor.sandbox.jtree.FilePreviewer$4.actionPerformed(FilePreviewer.java:115)
      1 frame
    3. Java RT
      EventDispatchThread.run
      1. javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
      2. javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
      3. javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
      4. javax.swing.DefaultButtonModel.setPressed(Unknown Source)
      5. javax.swing.AbstractButton.doClick(Unknown Source)
      6. javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
      7. javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown Source)
      8. java.awt.Component.processMouseEvent(Unknown Source)
      9. javax.swing.JComponent.processMouseEvent(Unknown Source)
      10. java.awt.Component.processEvent(Unknown Source)
      11. java.awt.Container.processEvent(Unknown Source)
      12. java.awt.Component.dispatchEventImpl(Unknown Source)
      13. java.awt.Container.dispatchEventImpl(Unknown Source)
      14. java.awt.Component.dispatchEvent(Unknown Source)
      15. java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
      16. java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
      17. java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
      18. java.awt.Container.dispatchEventImpl(Unknown Source)
      19. java.awt.Window.dispatchEventImpl(Unknown Source)
      20. java.awt.Component.dispatchEvent(Unknown Source)
      21. java.awt.EventQueue.dispatchEvent(Unknown Source)
      22. java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
      23. java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
      24. java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
      25. java.awt.EventDispatchThread.pumpEvents(Unknown Source)
      26. java.awt.EventDispatchThread.pumpEvents(Unknown Source)
      27. java.awt.EventDispatchThread.run(Unknown Source)
      27 frames