2025-02-10 20:53:40 +08:00
|
|
|
|
using System.Xml.Serialization;
|
|
|
|
|
|
|
2025-04-24 20:56:44 +08:00
|
|
|
|
namespace ShrlAlgoToolkit.RevitAddins.RvIndependent.MetroGauges.LandXMLData
|
2025-02-10 20:53:40 +08:00
|
|
|
|
{
|
|
|
|
|
|
[XmlType("CgPoint")]
|
|
|
|
|
|
public class CgPoint : TextPoint3D
|
|
|
|
|
|
{
|
|
|
|
|
|
[XmlAttribute("name")]
|
|
|
|
|
|
public string Name { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
[XmlAttribute("code")]
|
|
|
|
|
|
public string Code { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
[XmlAttribute("pntRef")]
|
|
|
|
|
|
public string PntRef { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
public override bool Equals(object obj)
|
|
|
|
|
|
{
|
|
|
|
|
|
return this == (CgPoint)obj;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public override int GetHashCode()
|
|
|
|
|
|
{
|
|
|
|
|
|
return base.GetHashCode();
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public static bool operator ==(CgPoint p1, CgPoint p2)
|
|
|
|
|
|
{
|
|
|
|
|
|
return p1 == p2 && (p1 == null || (p1.Name == p2.Name && p1.Code == p2.Code && p1.PntRef == p2.PntRef));
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public static bool operator !=(CgPoint p1, CgPoint p2)
|
|
|
|
|
|
{
|
|
|
|
|
|
return p1 != p2 || (p1 != null && p1.Name != p2.Name && p1.Code != p2.Code && p1.PntRef != p2.PntRef);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|