예제 #1
0
        public string GetErrorMessage(int tabs = 0)
        {
            var errorMessage = new IndentStringBuilder
            {
                Indent = tabs
            };

            var debugText = GetDebugErrorMessage();

            errorMessage.WriteLine(debugText);

            if (InnerErrors.Length > 0)
            {
                errorMessage.Indent++;
                foreach (var innerError in InnerErrors)
                {
                    errorMessage.WriteLine(innerError.GetErrorMessage(tabs + 2));
                }

                errorMessage.Indent--;
            }

            return(errorMessage.ToString());
        }