using System;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;
using System.Text;
namespace System.IO
{
/// The exception that is thrown when a managed assembly is found but cannot be loaded.
/// 2
// Token: 0x020001B6 RID: 438
[ComVisible(true)]
[Serializable]
public class FileLoadException : IOException
{
/// Initializes a new instance of the class, setting the property of the new instance to a system-supplied message that describes the error, such as "Could not load the specified file." This message takes into account the current system culture.
// Token: 0x06001683 RID: 5763 RVA: 0x00056920 File Offset: 0x00054B20
public FileLoadException()
: base(Locale.GetText("I/O Error"))
{
base.HResult = -2147024894;
this.msg = Locale.GetText("I/O Error");
}
/// Initializes a new instance of the class with the specified error message.
/// A that describes the error. The content of is intended to be understood by humans. The caller of this constructor is required to ensure that this string has been localized for the current system culture.
// Token: 0x06001684 RID: 5764 RVA: 0x00056958 File Offset: 0x00054B58
public FileLoadException(string message)
: base(message)
{
base.HResult = -2147024894;
this.msg = message;
}
/// Initializes a new instance of the class with a specified error message and the name of the file that could not be loaded.
/// A that describes the error. The content of is intended to be understood by humans. The caller of this constructor is required to ensure that this string has been localized for the current system culture.
/// A containing the name of the file that was not loaded.
// Token: 0x06001685 RID: 5765 RVA: 0x00056974 File Offset: 0x00054B74
public FileLoadException(string message, string fileName)
: base(message)
{
base.HResult = -2147024894;
this.msg = message;
this.fileName = fileName;
}
/// 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.
/// A that describes the error. The content of is intended to be understood by humans. The caller of this constructor is required to ensure that this string has been localized for the current system culture.
/// The exception that is the cause of the current exception. If the parameter is not null, the current exception is raised in a catch block that handles the inner exception.
// Token: 0x06001686 RID: 5766 RVA: 0x000569A4 File Offset: 0x00054BA4
public FileLoadException(string message, Exception inner)
: base(message, inner)
{
base.HResult = -2147024894;
this.msg = message;
}
/// Initializes a new instance of the class with a specified error message, the name of the file that could not be loaded, and a reference to the inner exception that is the cause of this exception.
/// A that describes the error. The content of is intended to be understood by humans. The caller of this constructor is required to ensure that this string has been localized for the current system culture.
/// A containing the name of the file that was not loaded.
/// The exception that is the cause of the current exception. If the parameter is not null, the current exception is raised in a catch block that handles the inner exception.
// Token: 0x06001687 RID: 5767 RVA: 0x000569C0 File Offset: 0x00054BC0
public FileLoadException(string message, string fileName, Exception inner)
: base(message, inner)
{
base.HResult = -2147024894;
this.msg = message;
this.fileName = fileName;
}
/// Initializes a new instance of the class with serialized data.
/// The that holds the serialized object data about the exception being thrown.
/// The that contains contextual information about the source or destination.
// Token: 0x06001688 RID: 5768 RVA: 0x000569E4 File Offset: 0x00054BE4
protected FileLoadException(SerializationInfo info, StreamingContext context)
{
this.fileName = info.GetString("FileLoad_FileName");
this.fusionLog = info.GetString("FileLoad_FusionLog");
}
/// Gets the error message and the name of the file that caused this exception.
/// A string containing the error message and the name of the file that caused this exception.
/// 2
// Token: 0x170003F2 RID: 1010
// (get) Token: 0x06001689 RID: 5769 RVA: 0x00056A1C File Offset: 0x00054C1C
public override string Message
{
get
{
return this.msg;
}
}
/// Gets the name of the file that causes this exception.
/// A containing the name of the file with the invalid image, or a null reference if no file name was passed to the constructor for the current instance.
/// 2
// Token: 0x170003F3 RID: 1011
// (get) Token: 0x0600168A RID: 5770 RVA: 0x00056A24 File Offset: 0x00054C24
public string FileName
{
get
{
return this.fileName;
}
}
/// Gets the log file that describes why an assembly load failed.
/// A string containing errors reported by the assembly cache.
/// The caller does not have the required permission.
/// 2
///
///
///
// Token: 0x170003F4 RID: 1012
// (get) Token: 0x0600168B RID: 5771 RVA: 0x00056A2C File Offset: 0x00054C2C
public string FusionLog
{
get
{
return this.fusionLog;
}
}
/// Sets the with the file name and additional exception information.
/// The that holds the serialized object data about the exception being thrown.
/// The that contains contextual information about the source or destination.
/// The caller does not have the required permission.
/// 2
///
///
///
///
// Token: 0x0600168C RID: 5772 RVA: 0x00056A34 File Offset: 0x00054C34
public override void GetObjectData(SerializationInfo info, StreamingContext context)
{
base.GetObjectData(info, context);
info.AddValue("FileLoad_FileName", this.fileName);
info.AddValue("FileLoad_FusionLog", this.fusionLog);
}
/// Returns the fully qualified name of the current exception, and possibly the error message, the name of the inner exception, and the stack trace.
/// A string containing the fully qualified name of this exception, and possibly the error message, the name of the inner exception, and the stack trace, depending on which constructor is used.
/// 2
///
///
///
// Token: 0x0600168D RID: 5773 RVA: 0x00056A6C File Offset: 0x00054C6C
public override string ToString()
{
StringBuilder stringBuilder = new StringBuilder(this.GetType().FullName);
stringBuilder.AppendFormat(": {0}", this.msg);
if (this.fileName != null)
{
stringBuilder.AppendFormat(" : {0}", this.fileName);
}
if (this.InnerException != null)
{
stringBuilder.AppendFormat(" ----> {0}", this.InnerException);
}
if (this.StackTrace != null)
{
stringBuilder.Append(Environment.NewLine);
stringBuilder.Append(this.StackTrace);
}
return stringBuilder.ToString();
}
// Token: 0x0400066F RID: 1647
private const int Result = -2147024894;
// Token: 0x04000670 RID: 1648
private string msg;
// Token: 0x04000671 RID: 1649
private string fileName;
// Token: 0x04000672 RID: 1650
private string fusionLog;
}
}