code: private SearchIndex makeSuggestIndex(StaplerRequest req) {
          SearchIndexBuilder builder = new SearchIndexBuilder();
          for (Ancestor a : req.getAncestors()) {
              if (a.getObject() instanceof SearchableModelObject) {
                  SearchableModelObject smo = (SearchableModelObject) a.getObject();
                  builder.add(smo.getSearchIndex());
              }
          }
          return builder.make();
      }
docs: Creates merged search index for suggestion.