code: public ImmutableSortedSet<String> getTransitiveIjParamsForTemplate(String templateName) {
      TemplateData templateData = getTemplateData(templateName);
      ImmutableSortedSet<String> transitiveIjParams = templateData.transitiveIjParams;
      // racy-lazy init pattern.  We may calculate this more than once, but that is fine because each
      // time should calculate the same value.
      if (transitiveIjParams != null) {
        // early return, we already calculated this.
        return transitiveIjParams;
      }
      Set<TemplateData> all = new HashSet<>();
      collectTransitiveCallees(templateData, all);
      ImmutableSortedSet.Builder<String> ijs = ImmutableSortedSet.naturalOrder();
      for (TemplateData callee : all) {
        ijs.addAll(callee.injectedParams);
      }
      transitiveIjParams = ijs.build();
      // save the results
      templateData.transitiveIjParams = transitiveIjParams;
      return transitiveIjParams;
    }
docs: Returns the transitive closure of all the injected params that might be used by this template.