added equals methods to base thermo object
This commit is contained in:
@@ -1,44 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace CMS_CORE_Library.Models
|
||||
{
|
||||
public class ThermoModels
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents thermo gauge data
|
||||
/// </summary>
|
||||
public class GaugeModel
|
||||
{
|
||||
public uint TimeAdv { get; set; } = 0;
|
||||
public int Power { get; set; } = 0;
|
||||
public int Vacuum { get; set; } = 0;
|
||||
public int Air { get; set; } = 0;
|
||||
|
||||
public override bool Equals(object obj)
|
||||
{
|
||||
// Object is not a DTOProcessDataModel instance
|
||||
if (!(obj is GaugeModel item))
|
||||
return false;
|
||||
|
||||
if (TimeAdv != item.TimeAdv)
|
||||
return false;
|
||||
|
||||
if (Power != item.Power)
|
||||
return false;
|
||||
|
||||
if (Vacuum != item.Vacuum)
|
||||
return false;
|
||||
|
||||
if (Air != item.Air)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user