/// <summary> /// Returns true if ResponseTravelTimeStatistics instances are equal /// </summary> /// <param name="other">Instance of ResponseTravelTimeStatistics to be compared</param> /// <returns>Boolean</returns> public bool Equals(ResponseTravelTimeStatistics other) { if (other is null) return false; if (ReferenceEquals(this, other)) return true; return ( Min == other.Min || Min.Equals(other.Min) ) && ( Max == other.Max || Max.Equals(other.Max) ) && ( Mean == other.Mean || Mean.Equals(other.Mean) ) && ( Median == other.Median || Median.Equals(other.Median) ); }
void price_changed(object sender, PropertyChangedEventArgs e) { double d; if (!(double.TryParse(Max, out d)) && !Max.Equals("")) { Thickness myThickness = new Thickness(2, 2, 2, 2); max_box.BorderBrush = Brushes.Red; max_box.BorderThickness = myThickness; } else { Thickness myThickness = new Thickness(1, 1, 1, 1); max_box.BorderBrush = Brushes.Black; max_box.BorderThickness = myThickness; } if (!(double.TryParse(Min, out d)) && !Min.Equals("")) { Thickness myThickness = new Thickness(2, 2, 2, 2); min_box.BorderBrush = Brushes.Red; min_box.BorderThickness = myThickness; } else { Thickness myThickness = new Thickness(1, 1, 1, 1); min_box.BorderBrush = Brushes.Black; min_box.BorderThickness = myThickness; } }
public bool Equals(Bucket other) { if (other == null) { return(false); } return(Min.Equals(other.Min) && Max.Equals(other.Max)); }
public bool Equals(ClosedInterval <T> other) { if (other == null) { return(false); } return(Min.Equals(other.Min) && Max.Equals(other.Max)); }
public bool Equals(MRect?other) { if (other is null) { return(false); } return(Min.Equals(other.Min) && Max.Equals(other.Max)); }
/// <summary> Indicates if this range is contiguous with <code>range</code>. </summary> /// <param name="range">The range to check.</param> /// <returns>true if the two ranges are contiguous, false otherwise.</returns> /// <remarks>Contiguous can mean containing, overlapping, or being next to.</remarks> public bool IsContiguousWith([NotNull] Range <T> range) { if (Contains(range) || range.Contains(this)) { return(false); } // Once we remove overlapping and containing, only touching if available return(Max.Equals(range.Min) || Min.Equals(range.Max)); }
public override bool Equals(object obj) { var cmpr = obj as Box; if (cmpr == null) { return(false); } return(Min.Equals(cmpr.Min) && Max.Equals(cmpr.Max)); }
public bool Equals(Rect other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } if (Ps.Count != other.Ps.Count) { return(false); } for (int i = 0; i < Ps.Count; ++i) { var mine = Ps[i]; var theirs = other.Ps[i]; if (!Equals(mine, theirs)) { return(false); } } if (Ls.Count != other.Ls.Count) { return(false); } for (int i = 0; i < Ls.Count; ++i) { var mine = Ls[i]; var theirs = other.Ls[i]; if ((mine == null) != (theirs == null) || (mine != null && Math.Abs((double)mine - (double)theirs) >= 1E-06)) { return(false); } } if (LLs.Count != other.LLs.Count) { return(false); } for (int i = 0; i < LLs.Count; ++i) { var mine = LLs[i]; var theirs = other.LLs[i]; if (Math.Abs(mine - theirs) >= 1E-06) { return(false); } } return(Min.Equals(other.Min) && Max.Equals(other.Max) ); }
public bool Equals(Zone other) { if (other == null) { return(false); } return(Name.Equals(other.Name) && Min.Equals(other.Min) && Max.Equals(other.Max) && Type.Equals(other.Type) && Level.Equals(other.Level) && ZoneInfoDay.Equals(other.ZoneInfoDay) && ZoneInfoNight.Equals(other.ZoneInfoNight) && ChildZoneIndex.Equals(other.ChildZoneIndex) && ParentZoneIndex.Equals(other.ParentZoneIndex) && NextZoneIndex.Equals(other.NextZoneIndex)); }
public override bool Equals(object obj) { if (!(obj is Region3 other)) { return(false); } if (!Min.Equals(other.Min)) { return(false); } if (!Max.Equals(other.Max)) { return(false); } return(true); }
public override bool Equals(object obj) { if (!(obj is Region3int16)) { return(false); } var other = obj as Region3int16; if (!Min.Equals(other.Min)) { return(false); } if (!Max.Equals(other.Max)) { return(false); } return(true); }
public bool Equals(Aabb?other) { return(other != null && Min.Equals(other.Min) && Max.Equals(other.Max)); }
public bool Equals(Bucket other) { return(Min.Equals(other?.Min) && Max.Equals(other?.Max)); }
public bool Equals(Bucket other) => Min.Equals(other?.Min) && Max.Equals(other?.Max);
protected bool Equals(CardMinMaxCurrent other) { return(Min.Equals(other.Min) && Max.Equals(other.Max) && Current.Equals(other.Current)); }
public bool Equals(Rect other) { return(Min.Equals(other.Min) && Max.Equals(other.Max)); }
protected bool Equals(Temp other) { return(Day.Equals(other.Day) && Min.Equals(other.Min) && Max.Equals(other.Max) && Night.Equals(other.Night) && Eve.Equals(other.Eve) && Morn.Equals(other.Morn)); }
private void filter() { if (chack_filter.IsChecked.Equals(true)) { double max, min; double d; if (Max.Equals("")) { max = double.MaxValue; } else if (!(double.TryParse(Max, out d))) { return; } else { max = d; } if (Min.Equals("")) { min = double.MinValue; } else if (!(double.TryParse(Min, out d))) { return; } else { min = d; } List <Res> l = new List <Res>( ); listRes.Clear( ); for (int i = 0; i < MainWindow.Resources.Len( ); i++) { WpfApp3.Res r = MainWindow.Resources.GetResourceAtI(i); String ek = r.eksploatisanje ? "DA" : "NE"; String o = r.obnovljiv ? "DA" : "NE"; String s = r.strateskiVazan ? "DA" : "NE"; Regex match = new Regex(Ime, RegexOptions.IgnoreCase); Match mIme = match.Match(r.ime); match = new Regex(Oznaka, RegexOptions.IgnoreCase); Match mOznaka = match.Match(r.oznaka); String etiketeStr = ""; for (int j = 0; j < r.etikete.Count; j++) { etiketeStr += r.etikete[j].oznaka + " "; } Double cena = double.Parse(r.cena); if ((r.ime.StartsWith(Ime) || Ime.Equals("")) && (r.oznaka.StartsWith(Oznaka) || Oznaka.Equals("")) && (Tip.Equals("") || Tip.Equals(r.tip)) && cena <= max && cena >= min) { l.Add(new Res( ) { Ime = r.ime, Opis = r.opis, Oznaka = r.oznaka, Tip = r.tip, Slika = r.tipImg, Frekvencija = r.frekvencija, Ikonica = r.oznaka, Obnovljiv = o, Eksploatisanje = ek, StrateskiVazan = s, Mera = r.mera, Cena = r.cena, Datum = r.datum, Etikete = etiketeStr }); listRes.Add(new Res( ) { Ime = r.ime, Opis = r.opis, Oznaka = r.oznaka, Tip = r.tip, Slika = r.tipImg, Frekvencija = r.frekvencija, Ikonica = r.oznaka, Obnovljiv = o, Eksploatisanje = ek, StrateskiVazan = s, Mera = r.mera, Cena = r.cena, Datum = r.datum, Etikete = etiketeStr }); } } } }
public override Dictionary <string, object> ToUpdate(IMemoryCache memoryCache, out BaseModel updatedElement) { Dictionary <string, object> changes = new Dictionary <string, object>(); PropertyKey refInCache = null; if (Id != string.Empty) { refInCache = CacheHelper.GetPropertyKeyFromCache(memoryCache, Id); if (refInCache != null) { if (!Name.Equals(refInCache.Name)) { changes.Add("Name", Name); } if (!PrimitiveDataType.Equals(refInCache.PrimitiveDataType)) { changes.Add("PrimitiveDataType", this.PrimitiveDataType.ToString()); } if (!Category.Equals(refInCache.Category)) { changes.Add("Category", Category); } if (!Description.Equals(refInCache.Description)) { changes.Add("Description", Description); } if (!SpaceId.Equals(refInCache.SpaceId)) { changes.Add("SpaceId", SpaceId); } if (!Scope.Equals(refInCache.Scope)) { changes.Add("Scope", Scope.ToString()); } if (!ValidationData.Equals(refInCache.ValidationData)) { changes.Add("ValidationData", ValidationData); } if (!Min.Equals(refInCache.Min)) { changes.Add("Min", Min); } if (!Max.Equals(refInCache.Max)) { changes.Add("Max", Max); } } else { refInCache = this; if (Name != null) { changes.Add("Name", Name); } changes.Add("PrimitiveDataType", this.PrimitiveDataType.ToString()); if (Category != null) { changes.Add("Category", Category); } if (Description != null) { changes.Add("Description", Description); } if (SpaceId != null) { changes.Add("SpaceId", SpaceId); } changes.Add("Scope", Scope.ToString()); if (ValidationData != null) { changes.Add("ValidationData", ValidationData); } if (Min != null) { changes.Add("Min", Min); } if (Max != null) { changes.Add("Max", Max); } } } updatedElement = refInCache; return(changes); }
/// <summary> /// Returns true if IngredientObjectNutrients instances are equal /// </summary> /// <param name="other">Instance of IngredientObjectNutrients to be compared</param> /// <returns>Boolean</returns> public bool Equals(IngredientObjectNutrients other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return (( Name == other.Name || Name != null && Name.Equals(other.Name) ) && ( Per100g == other.Per100g || Per100g != null && Per100g.Equals(other.Per100g) ) && ( MeasurementUnit == other.MeasurementUnit || MeasurementUnit != null && MeasurementUnit.Equals(other.MeasurementUnit) ) && ( Min == other.Min || Min != null && Min.Equals(other.Min) ) && ( Max == other.Max || Max != null && Max.Equals(other.Max) ) && ( Median == other.Median || Median != null && Median.Equals(other.Median) ) && ( Rank == other.Rank || Rank != null && Rank.Equals(other.Rank) ) && ( DataPoints == other.DataPoints || DataPoints != null && DataPoints.Equals(other.DataPoints) ) && ( Footnote == other.Footnote || Footnote != null && Footnote.Equals(other.Footnote) ) && ( Description == other.Description || Description != null && Description.Equals(other.Description) )); }
public bool Equals(Bounds2D other) { return(Min.Equals(other.Min) && Max.Equals(other.Max)); }
/// <summary> /// Returns true if ConfigDescriptionParameterDTO instances are equal /// </summary> /// <param name="input">Instance of ConfigDescriptionParameterDTO to be compared</param> /// <returns>Boolean</returns> public bool Equals(ConfigDescriptionParameterDTO input) { if (input == null) { return(false); } return (( Context == input.Context || (Context != null && Context.Equals(input.Context)) ) && ( DefaultValue == input.DefaultValue || (DefaultValue != null && DefaultValue.Equals(input.DefaultValue)) ) && ( Description == input.Description || (Description != null && Description.Equals(input.Description)) ) && ( Label == input.Label || (Label != null && Label.Equals(input.Label)) ) && ( Name == input.Name || (Name != null && Name.Equals(input.Name)) ) && ( Required == input.Required || (Required != null && Required.Equals(input.Required)) ) && ( Type == input.Type || (Type != null && Type.Equals(input.Type)) ) && ( Min == input.Min || (Min != null && Min.Equals(input.Min)) ) && ( Max == input.Max || (Max != null && Max.Equals(input.Max)) ) && ( Stepsize == input.Stepsize || (Stepsize != null && Stepsize.Equals(input.Stepsize)) ) && ( Pattern == input.Pattern || (Pattern != null && Pattern.Equals(input.Pattern)) ) && ( ReadOnly == input.ReadOnly || (ReadOnly != null && ReadOnly.Equals(input.ReadOnly)) ) && ( Multiple == input.Multiple || (Multiple != null && Multiple.Equals(input.Multiple)) ) && ( MultipleLimit == input.MultipleLimit || (MultipleLimit != null && MultipleLimit.Equals(input.MultipleLimit)) ) && ( GroupName == input.GroupName || (GroupName != null && GroupName.Equals(input.GroupName)) ) && ( Advanced == input.Advanced || (Advanced != null && Advanced.Equals(input.Advanced)) ) && ( Verify == input.Verify || (Verify != null && Verify.Equals(input.Verify)) ) && ( LimitToOptions == input.LimitToOptions || (LimitToOptions != null && LimitToOptions.Equals(input.LimitToOptions)) ) && ( Unit == input.Unit || (Unit != null && Unit.Equals(input.Unit)) ) && ( UnitLabel == input.UnitLabel || (UnitLabel != null && UnitLabel.Equals(input.UnitLabel)) ) && ( Options == input.Options || Options != null && Options.SequenceEqual(input.Options) ) && ( FilterCriteria == input.FilterCriteria || FilterCriteria != null && FilterCriteria.SequenceEqual(input.FilterCriteria) )); }
private void Button_Click(object sender, RoutedEventArgs e) { double max, min; double d; if (Max.Equals("")) { max = double.MaxValue; } else if (!(double.TryParse(Max, out d))) { return; } else { max = d; } if (Min.Equals("")) { min = double.MinValue; } else if (!(double.TryParse(Min, out d))) { return; } else { min = d; } List <Res> l = new List <Res>( ); listRes.Clear( ); for (int i = 0; i < MainWindow.Resources.Len( ); i++) { WpfApp3.Res r = MainWindow.Resources.GetResourceAtI(i); String ek = r.eksploatisanje ? "DA" : "NE"; String o = r.obnovljiv ? "DA" : "NE"; String s = r.strateskiVazan ? "DA" : "NE"; Regex match = new Regex(Ime, RegexOptions.IgnoreCase); Match mIme = match.Match(r.ime); match = new Regex(Oznaka, RegexOptions.IgnoreCase); Match mOznaka = match.Match(r.oznaka); String etiketeStr = ""; for (int j = 0; j < r.etikete.Count; j++) { etiketeStr += r.etikete[j].oznaka + " "; } Double cena = double.Parse(r.cena); if (((mIme.Success && mIme.Value.Length == r.ime.Length) || Ime.Equals("")) && ((mOznaka.Success && mOznaka.Value.Length == r.oznaka.Length) || Oznaka.Equals("")) && (Tip.Equals("") || Tip.Equals(r.tip)) && cena <= max && cena >= min) { l.Add(new Res( ) { Ime = r.ime, Opis = r.opis, Oznaka = r.oznaka, Tip = r.tip, Slika = r.tipImg, Frekvencija = r.frekvencija, Ikonica = r.oznaka, Obnovljiv = o, Eksploatisanje = ek, StrateskiVazan = s, Mera = r.mera, Cena = r.cena, Datum = r.datum, Etikete = etiketeStr }); listRes.Add(new Res( ) { Ime = r.ime, Opis = r.opis, Oznaka = r.oznaka, Tip = r.tip, Slika = r.tipImg, Frekvencija = r.frekvencija, Ikonica = r.oznaka, Obnovljiv = o, Eksploatisanje = ek, StrateskiVazan = s, Mera = r.mera, Cena = r.cena, Datum = r.datum, Etikete = etiketeStr }); } } /*this.Close( ); * var tablefil = new Table(l); * tablefil.ShowDialog( );*/ }
protected bool Equals(ObservationResult other) { return(string.Equals(Area, other.Area) && string.Equals(Point, other.Point) && First.Equals(other.First) && Max.Equals(other.Max) && Height.Equals(other.Height) && Rising == other.Rising); }