docs: private void outputIndexTerm(final IndexTerm term, final XMLSerializer serializer) throws SAXException {
          List<IndexTermTarget> targets = term.getTargetList();
          final List<IndexTerm> subTerms = term.getSubTerms();
          int targetNum = targets.size();
          final int subTermNum = subTerms.size();
  
          serializer.writeStartElement("li");
          serializer.writeStartElement("object");
          serializer.writeAttribute("type", "text/sitemap");
          serializer.writeStartElement("param");
          serializer.writeAttribute("name", "Name");
          serializer.writeAttribute("value", term.getTermFullName());
          serializer.writeEndElement(); // param
          //if term doesn't has target to link to, it won't appear in the index tab
          //we need to create links for such terms
          if (targets.isEmpty()){
              findTargets(term);
              targets = term.getTargetList();
              targetNum = targets.size();
          }
          for (int i = 0; i < targetNum; i++) {
              final IndexTermTarget target = targets.get(i);
              serializer.writeStartElement("param");
              serializer.writeAttribute("name", "Name");
              serializer.writeAttribute("value", target.getTargetName());
              serializer.writeEndElement(); // param
              serializer.writeStartElement("param");
              serializer.writeAttribute("name", "Local");
              serializer.writeAttribute("value", target.getTargetURI());
              serializer.writeEndElement(); // param
          }
          serializer.writeEndElement(); // object
          if (subTermNum > 0) {
              serializer.writeStartElement("ul");
              for (final IndexTerm subTerm : subTerms) {
                  outputIndexTerm(subTerm, serializer);
              }
              serializer.writeEndElement(); // ul
          }
          serializer.writeEndElement(); // li
      }