code: public SortedSet<ClassDoc> allSubs(ClassDoc cd, boolean isEnum) {
          // new entries added to the list are searched as well
          List<ClassDoc> list = new ArrayList<>(subs(cd, isEnum));
          for (int i = 0; i < list.size(); i++) {
              cd = list.get(i);
              SortedSet<ClassDoc> tlist = subs(cd, isEnum);
              for (ClassDoc tcd : tlist) {
                  if (!list.contains(tcd)) {
                      list.add(tcd);
                  }
              }
          }
          SortedSet<ClassDoc> oset = new TreeSet<>(comparator);
          oset.addAll(list);
          return oset;
      }
docs: Return a list of all direct or indirect, sub-classes and subinterfaces
  of the ClassDoc argument.
  
  @param cd ClassDoc whose sub-classes or sub-interfaces are requested.
  @param isEnum true if the subclasses should be forced to come from the
  enum tree.