public override int GetHashCode() { unchecked { var hashCode = (Id != null ? Id.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Name != null ? Name.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (LastPoint != null ? LastPoint.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (int)State; return(hashCode); } }