// Copyright Epic Games, Inc. All Rights Reserved. using System; using System.Collections.Generic; using System.Text; namespace UnrealBuildTool { /// /// Base class for exceptions thrown by UBT /// public class BuildException : Exception { /// /// Constructor /// /// The error message to display. public BuildException(string Message) : base(Message) { } /// /// Constructor /// /// An inner exception to wrap /// The error message to display. public BuildException(Exception InnerException, string Message) : base(Message, InnerException) { } /// /// Constructor /// /// Formatting string for the error message /// Arguments for the formatting string public BuildException(string Format, params object?[] Arguments) : base(String.Format(Format, Arguments)) { } /// /// Constructor which wraps another exception /// /// The inner exception being wrapped /// Format for the message string /// Format arguments public BuildException(Exception InnerException, string Format, params object?[] Arguments) : base(String.Format(Format, Arguments), InnerException) { } /// /// Returns the string representing the exception. Our build exceptions do not show the callstack since they are used to report known error conditions. /// /// Message for the exception public override string ToString() { return Message; } } }