public override int GetHashCode() { unchecked { var hashCode = EntryDateTimeOffset.GetHashCode(); hashCode = (hashCode * 397) ^ (Point != null ? Point.GetHashCode() : 0); hashCode = (hashCode * 397) ^ Heading.GetHashCode(); hashCode = (hashCode * 397) ^ Pitch.GetHashCode(); hashCode = (hashCode * 397) ^ Roll.GetHashCode(); return(hashCode); } }
public bool Equals(CompassLogEntry other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(EntryDateTimeOffset.Equals(other.EntryDateTimeOffset) && Equals(Point, other.Point) && Heading.Equals(other.Heading) && Pitch.Equals(other.Pitch) && Roll.Equals(other.Roll)); }
public override string ToString() { return(string.Format(CultureInfo.InvariantCulture, "{0},{1},{2},{3},{4},{5}", EntryDateTimeOffset.ToUnixTimeMilliseconds(), Point?.Latitude.ToDegrees(), Point?.Longitude.ToDegrees(), Heading, Pitch, Roll)); }