code: @SuppressWarnings("ReferenceEquality")
    public boolean hasTemplateKey(TemplateType templateKey) {
      // Note: match by identity, not equality
      for (TemplateType entry : templateKeys) {
        if (entry == templateKey) {
          return true;
        }
      }
      return false;
    }
docs: Returns true if this map contains the specified template key, false
  otherwise.