2019-11-02 01:15:49 +00:00
|
|
|
using System;
|
|
|
|
|
|
2020-02-27 00:33:26 +00:00
|
|
|
namespace Aaru.Devices
|
2019-11-02 01:15:49 +00:00
|
|
|
{
|
2020-02-29 18:03:35 +00:00
|
|
|
/// <summary>Exception to be returned by the device constructor</summary>
|
2019-11-02 01:15:49 +00:00
|
|
|
public class DeviceException : Exception
|
|
|
|
|
{
|
2020-02-29 18:03:35 +00:00
|
|
|
internal DeviceException(string message) : base(message) {}
|
2019-11-02 01:15:49 +00:00
|
|
|
|
2020-02-29 18:03:35 +00:00
|
|
|
internal DeviceException(int lastError) => LastError = lastError;
|
2019-11-02 01:15:49 +00:00
|
|
|
|
2020-02-29 18:03:35 +00:00
|
|
|
/// <summary>Last error sent by the operating systen</summary>
|
2019-11-02 01:15:49 +00:00
|
|
|
public int LastError { get; }
|
|
|
|
|
}
|
|
|
|
|
}
|