ReSharper: -Registers
This commit is contained in:
@@ -152,7 +152,7 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.GenesisCore
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Represent <see cref="Register.Configexchange.PCBSerialNumber" />
|
||||
/// Represent <see cref="Register.Configexchange.PcbSerialNumber" />
|
||||
/// proposed for login
|
||||
/// </summary>
|
||||
public String PcbId
|
||||
@@ -1647,7 +1647,7 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.GenesisCore
|
||||
var maxReads = 4;
|
||||
while (!hasZero)
|
||||
{
|
||||
var chunk = ReadRegister(Register.Configexchange.PCBSerialNumber, 4);
|
||||
var chunk = ReadRegister(Register.Configexchange.PcbSerialNumber, 4);
|
||||
maxReads -= 1;
|
||||
if (chunk == null)
|
||||
{
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
{
|
||||
// internal struct Enum8
|
||||
public struct Enum8
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
{
|
||||
public struct Rpc
|
||||
{
|
||||
|
||||
@@ -20,6 +20,7 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
/// <summary>
|
||||
/// Unknown to define restore capability
|
||||
/// </summary>
|
||||
// ReSharper disable once UnusedMember.Local
|
||||
private const String UnknownAccess = null;
|
||||
|
||||
/// <summary>
|
||||
@@ -30,11 +31,13 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
/// <summary>
|
||||
/// Denied restore capability
|
||||
/// </summary>
|
||||
// ReSharper disable once UnusedMember.Local
|
||||
private const String RestoreDenied = "dynamic";
|
||||
|
||||
/// <summary>
|
||||
/// Unpredictable restore capability
|
||||
/// </summary>
|
||||
// ReSharper disable once UnusedMember.Local
|
||||
private const String RestoreUnpredictable = "infrequentlyupdated";
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
{
|
||||
public struct StatusT
|
||||
{
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
{
|
||||
|
||||
public struct TimeT
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
{
|
||||
public class UInt96
|
||||
{
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
{
|
||||
internal class st_radio_dewa
|
||||
{
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.DataTypes
|
||||
{
|
||||
internal class st_radio_tfx
|
||||
{
|
||||
|
||||
@@ -128,9 +128,9 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers
|
||||
}
|
||||
else if(type == typeof(Boolean))
|
||||
{
|
||||
var checkValue = RegisterConverter.ConvertTo<Boolean>(value);
|
||||
|
||||
|
||||
// var checkValue = RegisterConverter.ConvertTo<Boolean>(value);
|
||||
RegisterConverter.ConvertTo<Boolean>(value);
|
||||
|
||||
//if (reg.Minimum.HasValue && checkValue < reg.Minimum.Value)
|
||||
//{
|
||||
// return MinText(true, checkValue.ToString(), reg.Minimum.Value.ToString(), reg.RegisterName);
|
||||
|
||||
@@ -99,24 +99,24 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override Boolean Equals(Object obj)
|
||||
{
|
||||
return obj is RegisterDefinition fooItem && GetHashCode() == fooItem.GetHashCode();
|
||||
}
|
||||
///// <inheritdoc />
|
||||
//public override Boolean Equals(Object obj)
|
||||
//{
|
||||
// return obj is RegisterDefinition fooItem && GetHashCode() == fooItem.GetHashCode();
|
||||
//}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override Int32 GetHashCode()
|
||||
{
|
||||
var hashCode = base.GetHashCode();
|
||||
if (RegisterDetail == null) return hashCode;
|
||||
hashCode ^= RegisterDetail.GetHashCode();
|
||||
if (RegisterDetail.Version != null)
|
||||
{
|
||||
hashCode ^= RegisterDetail.Version.GetHashCode();
|
||||
}
|
||||
///// <inheritdoc />
|
||||
//public override Int32 GetHashCode()
|
||||
//{
|
||||
// var hashCode = base.GetHashCode();
|
||||
// if (RegisterDetail == null) return hashCode;
|
||||
// hashCode ^= RegisterDetail.GetHashCode();
|
||||
// if (RegisterDetail.Version != null)
|
||||
// {
|
||||
// hashCode ^= RegisterDetail.Version.GetHashCode();
|
||||
// }
|
||||
|
||||
return hashCode;
|
||||
}
|
||||
// return hashCode;
|
||||
//}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers
|
||||
namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers.RegisterProperties
|
||||
{
|
||||
/// <summary>
|
||||
/// Representing the 8 access levels meter register can have
|
||||
|
||||
@@ -34,7 +34,7 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers
|
||||
{
|
||||
public static readonly String Privilege = "CONFIGEXCHANGE_Privilege";
|
||||
public static readonly String Password = "CONFIGEXCHANGE_Password";
|
||||
public static readonly String PCBSerialNumber = "CONFIGEXCHANGE_PCBSerialNumber";
|
||||
public static readonly String PcbSerialNumber = "CONFIGEXCHANGE_PCBSerialNumber";
|
||||
public static readonly String FileOpen = "CONFIGEXCHANGE_FOpen";
|
||||
public static readonly String FileClose = "CONFIGEXCHANGE_FClose";
|
||||
public static readonly String FileWrite = "CONFIGEXCHANGE_FWrite";
|
||||
@@ -116,7 +116,7 @@ namespace Xylem.Common.Hardware.WaterMeter.Genesis.Registers
|
||||
{
|
||||
Configexchange.Privilege,
|
||||
Configexchange.Password,
|
||||
Configexchange.PCBSerialNumber,
|
||||
Configexchange.PcbSerialNumber,
|
||||
Configexchange.FileOpen,
|
||||
Configexchange.FileClose,
|
||||
Configexchange.FileWrite,
|
||||
|
||||
Reference in New Issue
Block a user