/// <summary> /// Returns true if ResponseInstruction instances are equal /// </summary> /// <param name="input">Instance of ResponseInstruction to be compared</param> /// <returns>Boolean</returns> public bool Equals(ResponseInstruction input) { if (input == null) { return(false); } return (( Text == input.Text || (Text != null && Text.Equals(input.Text)) ) && ( StreetName == input.StreetName || (StreetName != null && StreetName.Equals(input.StreetName)) ) && ( Distance == input.Distance || (Distance != null && Distance.Equals(input.Distance)) ) && ( Time == input.Time || (Time != null && Time.Equals(input.Time)) ) && ( Interval == input.Interval || Interval != null && Interval.SequenceEqual(input.Interval) ) && ( Sign == input.Sign || (Sign != null && Sign.Equals(input.Sign)) ) && ( AnnotationText == input.AnnotationText || (AnnotationText != null && AnnotationText.Equals(input.AnnotationText)) ) && ( AnnotationImportance == input.AnnotationImportance || (AnnotationImportance != null && AnnotationImportance.Equals(input.AnnotationImportance)) ) && ( ExitNumber == input.ExitNumber || (ExitNumber != null && ExitNumber.Equals(input.ExitNumber)) ) && ( TurnAngle == input.TurnAngle || (TurnAngle != null && TurnAngle.Equals(input.TurnAngle)) )); }
public virtual bool IsAt(string aStreetName) { return(StreetName.Equals(aStreetName)); }
// mainly here for unit tests public bool Equals(Address other) => (other != null) && StreetName.Equals(other.StreetName) && StreetNumber.Equals(other.StreetNumber);
/// <summary> /// Returns true if CommonPAFAddress instances are equal /// </summary> /// <param name="other">Instance of CommonPAFAddress to be compared</param> /// <returns>Boolean</returns> public bool Equals(CommonPAFAddress other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return (( Dpid == other.Dpid || Dpid != null && Dpid.Equals(other.Dpid) ) && ( ThoroughfareNumber1 == other.ThoroughfareNumber1 || ThoroughfareNumber1 != null && ThoroughfareNumber1.Equals(other.ThoroughfareNumber1) ) && ( ThoroughfareNumber1Suffix == other.ThoroughfareNumber1Suffix || ThoroughfareNumber1Suffix != null && ThoroughfareNumber1Suffix.Equals(other.ThoroughfareNumber1Suffix) ) && ( ThoroughfareNumber2 == other.ThoroughfareNumber2 || ThoroughfareNumber2 != null && ThoroughfareNumber2.Equals(other.ThoroughfareNumber2) ) && ( ThoroughfareNumber2Suffix == other.ThoroughfareNumber2Suffix || ThoroughfareNumber2Suffix != null && ThoroughfareNumber2Suffix.Equals(other.ThoroughfareNumber2Suffix) ) && ( FlatUnitNumber == other.FlatUnitNumber || FlatUnitNumber != null && FlatUnitNumber.Equals(other.FlatUnitNumber) ) && ( FloorLevelNumber == other.FloorLevelNumber || FloorLevelNumber != null && FloorLevelNumber.Equals(other.FloorLevelNumber) ) && ( LotNumber == other.LotNumber || LotNumber != null && LotNumber.Equals(other.LotNumber) ) && ( BuildingName1 == other.BuildingName1 || BuildingName1 != null && BuildingName1.Equals(other.BuildingName1) ) && ( BuildingName2 == other.BuildingName2 || BuildingName2 != null && BuildingName2.Equals(other.BuildingName2) ) && ( StreetName == other.StreetName || StreetName != null && StreetName.Equals(other.StreetName) ) && ( StreetType == other.StreetType || StreetType != null && StreetType.Equals(other.StreetType) ) && ( StreetSuffix == other.StreetSuffix || StreetSuffix != null && StreetSuffix.Equals(other.StreetSuffix) ) && ( PostalDeliveryType == other.PostalDeliveryType || PostalDeliveryType != null && PostalDeliveryType.Equals(other.PostalDeliveryType) ) && ( PostalDeliveryNumber == other.PostalDeliveryNumber || PostalDeliveryNumber != null && PostalDeliveryNumber.Equals(other.PostalDeliveryNumber) ) && ( PostalDeliveryNumberPrefix == other.PostalDeliveryNumberPrefix || PostalDeliveryNumberPrefix != null && PostalDeliveryNumberPrefix.Equals(other.PostalDeliveryNumberPrefix) ) && ( PostalDeliveryNumberSuffix == other.PostalDeliveryNumberSuffix || PostalDeliveryNumberSuffix != null && PostalDeliveryNumberSuffix.Equals(other.PostalDeliveryNumberSuffix) ) && ( LocalityName == other.LocalityName || LocalityName != null && LocalityName.Equals(other.LocalityName) ) && ( Postcode == other.Postcode || Postcode != null && Postcode.Equals(other.Postcode) ) && ( State == other.State || State != null && State.Equals(other.State) )); }