Class HelpTOCLoader


  • public class HelpTOCLoader
    extends java.lang.Object
    Help table-of-contents loader.

    Code for loading and constructing the table of contents (TOC). Doesn't refresh when plugins are (un)loaded: you'll have to call createTOC() again yourself.

    Don't keep HelpTOCLoader instances between loads: use it and forget it.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  HelpTOCLoader.HelpNode
      a TOC item: href and title.
    • Constructor Summary

      Constructors 
      Constructor Description
      HelpTOCLoader​(java.util.Map<java.lang.String,​javax.swing.tree.DefaultMutableTreeNode> nodes, java.lang.String baseURL)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      javax.swing.tree.DefaultMutableTreeNode createTOC()
      Load the table of contents.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • HelpTOCLoader

        public HelpTOCLoader​(java.util.Map<java.lang.String,​javax.swing.tree.DefaultMutableTreeNode> nodes,
                             java.lang.String baseURL)
    • Method Detail

      • createTOC

        public javax.swing.tree.DefaultMutableTreeNode createTOC()
        Load the table of contents. Performs synchronous IO, so you don't want to call it from the GUI thread.
        Returns:
        the TOC tree model as a DefaultMutableTreeNode. User objects are HelpTOCLoader.HelpNode instances.