code: protected void addIndexContents(Collection<ModuleElement> modules, String title, String tableSummary, Content body) {
          HtmlTree htmltree = (configuration.allowTag(HtmlTag.NAV))
                  ? HtmlTree.NAV()
                  : new HtmlTree(HtmlTag.DIV);
          htmltree.addStyle(HtmlStyle.indexNav);
          HtmlTree ul = new HtmlTree(HtmlTag.UL);
          addAllClassesLink(ul);
          if (configuration.showModules) {
              addAllModulesLink(ul);
          }
          htmltree.addContent(ul);
          body.addContent(htmltree);
          addModulesList(modules, title, tableSummary, body);
      }
docs: Adds module index contents.
  
  @param title the title of the section
  @param tableSummary summary for the table
  @param body the document tree to which the index contents will be added