/// <summary> /// Returns true if SummarySegment instances are equal /// </summary> /// <param name="other">Instance of SummarySegment to be compared</param> /// <returns>Boolean</returns> public bool Equals(SummarySegment other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return (( Id == other.Id || Id != null && Id.Equals(other.Id) ) && ( Name == other.Name || Name != null && Name.Equals(other.Name) ) && ( ActivityType == other.ActivityType || ActivityType != null && ActivityType.Equals(other.ActivityType) ) && ( Distance == other.Distance || Distance != null && Distance.Equals(other.Distance) ) && ( AverageGrade == other.AverageGrade || AverageGrade != null && AverageGrade.Equals(other.AverageGrade) ) && ( MaximumGrade == other.MaximumGrade || MaximumGrade != null && MaximumGrade.Equals(other.MaximumGrade) ) && ( ElevationHigh == other.ElevationHigh || ElevationHigh != null && ElevationHigh.Equals(other.ElevationHigh) ) && ( ElevationLow == other.ElevationLow || ElevationLow != null && ElevationLow.Equals(other.ElevationLow) ) && ( StartLatlng == other.StartLatlng || StartLatlng != null && StartLatlng.Equals(other.StartLatlng) ) && ( EndLatlng == other.EndLatlng || EndLatlng != null && EndLatlng.Equals(other.EndLatlng) ) && ( ClimbCategory == other.ClimbCategory || ClimbCategory != null && ClimbCategory.Equals(other.ClimbCategory) ) && ( City == other.City || City != null && City.Equals(other.City) ) && ( State == other.State || State != null && State.Equals(other.State) ) && ( Country == other.Country || Country != null && Country.Equals(other.Country) ) && ( _Private == other._Private || _Private != null && _Private.Equals(other._Private) ) && ( AthletePrEffort == other.AthletePrEffort || AthletePrEffort != null && AthletePrEffort.Equals(other.AthletePrEffort) ) && ( AthleteSegmentStats == other.AthleteSegmentStats || AthleteSegmentStats != null && AthleteSegmentStats.Equals(other.AthleteSegmentStats) )); }