public TTemplate Evaluate(TemplateContainer request) => throw new InvalidTemplateException($"No match found for template type {request.TemplateType}.", request.GetLineInfoForProperty(nameof(TemplateContainer.Template), true));
        private bool IsValid(TemplateContainer rootContainer, ICollection <TemplateError> errors)
        {
            if (!rootContainer.MatchTemplateName(TargetTemplateTypeName))
            {
                errors.Add(new TemplateError($"Expected {nameof(rootContainer.TemplateType)} value {TargetTemplateTypeName}, actual {rootContainer.TemplateType ?? "Not Found"}.", rootContainer.GetLineInfoForProperty(nameof(TemplateContainer.TemplateType))));
                return(false);
            }

            if (rootContainer.Template?.Type != JTokenType.Array)
            {
                errors.Add(new TemplateError($"Expected an array for the template property value for template type {TargetTemplateTypeName}.", rootContainer.GetLineInfoForProperty(nameof(TemplateContainer.Template))));
                return(false);
            }

            return(true);
        }