BeeSoft®
Since 1992
 

Content

 Welcome
 Products
       Abeona
       Gaia
             News
             Documentation
                   Introduction
                   Swing support
                         Components
                               JCalendar
                               Lazy tree loading
                               JTreeTable
                               Simple form
                               Form
                         Building from XML
                         Client / server
                   Server application
                   Validation
                   XML
                   Logging
                   Utilities
                   Launcher
             License
             Download
       Hephaistos
       JavaGantt
 Services
       Promote your software
 Contact Us
 Links
      
  GaiaI®
© 2012 BeeSoft ®
 

Lazy tree data loading

You can implement tree data lazy loading very easily with two classes:

  • ExplorableTreeNode - is an abstract descendant of javax.swing.tree.DefaultMutableTreeNode with enhanced expansion functionality capabilities. If this node has set the 'explorable' property and tree where this node is displayed has installed ExplorationTreeListener as tree expansion listener, then method exploreImpl() is invoked when this node is the first time displayed. Subclass and override this method to process lazy loading.
  • ExplorationTreeListener - is a listener which you can add to any tree - it listenes for expand / collapse events and if expanded node is instance of ExplorableTreeNode it invokes its method explore().