using System; using System.Runtime.InteropServices; using System.Runtime.Serialization; namespace System { /// The exception that is thrown when one of the arguments provided to a method is not valid. /// 1 // Token: 0x02000637 RID: 1591 [ComVisible(true)] [Serializable] public class ArgumentException : SystemException { /// Initializes a new instance of the class. // Token: 0x06003B0D RID: 15117 RVA: 0x000C98B0 File Offset: 0x000C7AB0 public ArgumentException() : base(Locale.GetText("Value does not fall within the expected range.")) { base.HResult = -2147024809; } /// Initializes a new instance of the class with a specified error message. /// The error message that explains the reason for the exception. // Token: 0x06003B0E RID: 15118 RVA: 0x000C98D0 File Offset: 0x000C7AD0 public ArgumentException(string message) : base(message) { base.HResult = -2147024809; } /// Initializes a new instance of the class with a specified error message and a reference to the inner exception that is the cause of this exception. /// The error message that explains the reason for the exception. /// The exception that is the cause of the current exception. If the parameter is not a null reference, the current exception is raised in a catch block that handles the inner exception. // Token: 0x06003B0F RID: 15119 RVA: 0x000C98E4 File Offset: 0x000C7AE4 public ArgumentException(string message, Exception innerException) : base(message, innerException) { base.HResult = -2147024809; } /// Initializes a new instance of the class with a specified error message and the name of the parameter that causes this exception. /// The error message that explains the reason for the exception. /// The name of the parameter that caused the current exception. // Token: 0x06003B10 RID: 15120 RVA: 0x000C98FC File Offset: 0x000C7AFC public ArgumentException(string message, string paramName) : base(message) { this.param_name = paramName; base.HResult = -2147024809; } /// Initializes a new instance of the class with a specified error message, the parameter name, and a reference to the inner exception that is the cause of this exception. /// The error message that explains the reason for the exception. /// The name of the parameter that caused the current exception. /// The exception that is the cause of the current exception. If the parameter is not a null reference, the current exception is raised in a catch block that handles the inner exception. // Token: 0x06003B11 RID: 15121 RVA: 0x000C9918 File Offset: 0x000C7B18 public ArgumentException(string message, string paramName, Exception innerException) : base(message, innerException) { this.param_name = paramName; base.HResult = -2147024809; } /// Initializes a new instance of the class with serialized data. /// The object that holds the serialized object data. /// The contextual information about the source or destination. // Token: 0x06003B12 RID: 15122 RVA: 0x000C9934 File Offset: 0x000C7B34 protected ArgumentException(SerializationInfo info, StreamingContext context) : base(info, context) { this.param_name = info.GetString("ParamName"); } /// Gets the name of the parameter that causes this exception. /// The parameter name. /// 1 // Token: 0x17000B50 RID: 2896 // (get) Token: 0x06003B13 RID: 15123 RVA: 0x000C9950 File Offset: 0x000C7B50 public virtual string ParamName { get { return this.param_name; } } /// Gets the error message and the parameter name, or only the error message if no parameter name is set. /// A text string describing the details of the exception. The value of this property takes one of two forms: Condition Value The is a null reference (Nothing in Visual Basic) or of zero length. The string passed to the constructor. The is not null reference (Nothing in Visual Basic) and it has a length greater than zero. The string appended with the name of the invalid parameter. /// 1 // Token: 0x17000B51 RID: 2897 // (get) Token: 0x06003B14 RID: 15124 RVA: 0x000C9958 File Offset: 0x000C7B58 public override string Message { get { if (this.ParamName != null && this.ParamName.Length != 0) { return base.Message + Environment.NewLine + Locale.GetText("Parameter name: ") + this.ParamName; } return base.Message; } } /// Sets the object with the parameter name and additional exception information. /// The object that holds the serialized object data. /// The contextual information about the source or destination. /// The object is a null reference (Nothing in Visual Basic). /// 2 /// /// /// // Token: 0x06003B15 RID: 15125 RVA: 0x000C99A8 File Offset: 0x000C7BA8 public override void GetObjectData(SerializationInfo info, StreamingContext context) { base.GetObjectData(info, context); info.AddValue("ParamName", this.ParamName); } // Token: 0x040017A1 RID: 6049 private const int Result = -2147024809; // Token: 0x040017A2 RID: 6050 private string param_name; } }