﻿// Decompiled with JetBrains decompiler
// Type: System.DataMisalignedException
// Assembly: mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
// MVID: 255ABCDF-D9D6-4E3D-BAD4-F74D4CE3D7A8
// Assembly location: C:\Windows\Microsoft.NET\Framework\v4.0.30319\mscorlib.dll

using System.Runtime;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;

namespace System
{
  /// <summary>
  /// The exception that is thrown when a unit of data is read from or written to an address that is not a multiple of the data size. This class cannot be inherited.
  /// </summary>
  /// <filterpriority>2</filterpriority>
  [ComVisible(true)]
  [__DynamicallyInvokable]
  [Serializable]
  public sealed class DataMisalignedException : SystemException
  {
    /// <summary>
    /// Initializes a new instance of the <see cref="T:System.DataMisalignedException"/> class.
    /// </summary>
    [__DynamicallyInvokable]
    public DataMisalignedException()
      : base(Environment.GetResourceString("Arg_DataMisalignedException"))
    {
      this.SetErrorCode(-2146233023);
    }

    /// <summary>
    /// Initializes a new instance of the <see cref="T:System.DataMisalignedException"/> class using the specified error message.
    /// </summary>
    /// <param name="message">A <see cref="T:System.String"/> object that describes the error. The content of <paramref name="message"/> 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. </param>
    [__DynamicallyInvokable]
    public DataMisalignedException(string message)
      : base(message)
    {
      this.SetErrorCode(-2146233023);
    }

    /// <summary>
    /// Initializes a new instance of the <see cref="T:System.DataMisalignedException"/> class using the specified error message and underlying exception.
    /// </summary>
    /// <param name="message">A <see cref="T:System.String"/> object that describes the error. The content of <paramref name="message"/> 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. </param><param name="innerException">The exception that is the cause of the current <see cref="T:System.DataMisalignedException"/>. If the <paramref name="innerException"/> parameter is not null, the current exception is raised in a catch block that handles the inner exception. </param>
    [__DynamicallyInvokable]
    public DataMisalignedException(string message, Exception innerException)
      : base(message, innerException)
    {
      this.SetErrorCode(-2146233023);
    }

    [TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]
    internal DataMisalignedException(SerializationInfo info, StreamingContext context)
      : base(info, context)
    {
    }
  }
}
