ApprovalUtilities.Utilities.ExceptionUtilities.GetExceptionLines C# (CSharp) Method

GetExceptionLines() public static method

public static GetExceptionLines ( Exception except ) : string[]
except System.Exception
return string[]
		public static string[] GetExceptionLines(Exception except, params string[] additional)
		{
			var lines = new List<string>
			            	{
			            		String.Format("Exception: '{0}' | '{1}'", except.TargetSite, except.Source),
			            		except.Message,
			            		except.StackTrace
			            	};
			lines.AddRange(additional);

			if (except.InnerException != null)
			{
				lines.AddRange(GetExceptionLines(except.InnerException));
			}

			return lines.ToArray();
		}