44 lines
1.3 KiB
C#
44 lines
1.3 KiB
C#
using System;
|
|
|
|
namespace Comio.BD15070_4
|
|
{
|
|
// Token: 0x0200051D RID: 1309
|
|
public static class ErrorNoEnum
|
|
{
|
|
// Token: 0x06002A06 RID: 10758 RVA: 0x00123DBF File Offset: 0x00122FBF
|
|
public static bool IsValid(this ErrorNo self)
|
|
{
|
|
return self >= ErrorNo.Begin && self < ErrorNo.End;
|
|
}
|
|
|
|
// Token: 0x06002A07 RID: 10759 RVA: 0x00123DCB File Offset: 0x00122FCB
|
|
public static string GetString(this ErrorNo self)
|
|
{
|
|
if (self.IsValid())
|
|
{
|
|
return ErrorNoEnum.Records[(int)self].String;
|
|
}
|
|
return "";
|
|
}
|
|
|
|
// Token: 0x06002A08 RID: 10760 RVA: 0x00123DE7 File Offset: 0x00122FE7
|
|
public static bool IsNeedFirmUpdate(this ErrorNo self)
|
|
{
|
|
return self.IsValid() && ErrorNoEnum.Records[(int)self].IsNeedFirmUpdate;
|
|
}
|
|
|
|
// Token: 0x04003B90 RID: 15248
|
|
private static readonly ErrorNoTableRecord[] Records = new ErrorNoTableRecord[]
|
|
{
|
|
new ErrorNoTableRecord(0, "None", false),
|
|
new ErrorNoTableRecord(0, "ComTimeout", false),
|
|
new ErrorNoTableRecord(0, "SumError", false),
|
|
new ErrorNoTableRecord(0, "ComResponse_ParamError", false),
|
|
new ErrorNoTableRecord(0, "ComResponse_Invalid", false),
|
|
new ErrorNoTableRecord(0, "FirmError", true),
|
|
new ErrorNoTableRecord(0, "FirmVersionError", true),
|
|
new ErrorNoTableRecord(0, "EEPRomWriteError", false)
|
|
};
|
|
}
|
|
}
|