/// <summary> /// Returns true if Demand instances are equal /// </summary> /// <param name="other">Instance of Demand to be compared</param> /// <returns>Boolean</returns> public bool Equals(Demand other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return (( DemandId == other.DemandId || DemandId != null && DemandId.Equals(other.DemandId) ) && ( RequestorId == other.RequestorId || RequestorId != null && RequestorId.Equals(other.RequestorId) )); }
public override bool Equals(object obj) { T_DemandToProvider other = (T_DemandToProvider)obj; return(DemandId.Equals(other.DemandId) && ProviderId.Equals(other.ProviderId)); }