public override bool Equals(object obj) { if (obj == null) { return(false); } if (obj == this) { return(true); } return(obj is CatalogItem other && ((Name == null && other.Name == null) || (Name?.Equals(other.Name) == true)) && ((Description == null && other.Description == null) || (Description?.Equals(other.Description) == true)) && ((Abbreviation == null && other.Abbreviation == null) || (Abbreviation?.Equals(other.Abbreviation) == true)) && ((LabelColor == null && other.LabelColor == null) || (LabelColor?.Equals(other.LabelColor) == true)) && ((AvailableOnline == null && other.AvailableOnline == null) || (AvailableOnline?.Equals(other.AvailableOnline) == true)) && ((AvailableForPickup == null && other.AvailableForPickup == null) || (AvailableForPickup?.Equals(other.AvailableForPickup) == true)) && ((AvailableElectronically == null && other.AvailableElectronically == null) || (AvailableElectronically?.Equals(other.AvailableElectronically) == true)) && ((CategoryId == null && other.CategoryId == null) || (CategoryId?.Equals(other.CategoryId) == true)) && ((TaxIds == null && other.TaxIds == null) || (TaxIds?.Equals(other.TaxIds) == true)) && ((ModifierListInfo == null && other.ModifierListInfo == null) || (ModifierListInfo?.Equals(other.ModifierListInfo) == true)) && ((Variations == null && other.Variations == null) || (Variations?.Equals(other.Variations) == true)) && ((ProductType == null && other.ProductType == null) || (ProductType?.Equals(other.ProductType) == true)) && ((SkipModifierScreen == null && other.SkipModifierScreen == null) || (SkipModifierScreen?.Equals(other.SkipModifierScreen) == true)) && ((ItemOptions == null && other.ItemOptions == null) || (ItemOptions?.Equals(other.ItemOptions) == true))); }
public override bool Equals(object obj) { if (obj == null) { return(false); } CompassDirection other = obj as CompassDirection; return(Abbreviation.Equals(other.Abbreviation)); }
public bool Equals(Enumeration other) { if (other == null) { return(false); } var typeMatches = GetType().Equals(other.GetType()); var valueMatches = Abbreviation.Equals(other.Abbreviation); return(typeMatches && valueMatches); }
public override bool Equals(object other) { if (other is string unit) { return(Name.Equals(unit, StringComparison.OrdinalIgnoreCase) || ToPlural(Name).Equals(unit, StringComparison.OrdinalIgnoreCase) || Abbreviation.Equals(unit, StringComparison.OrdinalIgnoreCase)); } else { return(this == other); } }
public override bool Equals(object obj) { CompassDirection other = obj as CompassDirection; return(Abbreviation.Equals(other.Abbreviation)); }
public bool Equals(IState other) { return(Abbreviation.Equals(other.Abbreviation, StringComparison.CurrentCultureIgnoreCase) && Name.Equals(other.Name, StringComparison.CurrentCultureIgnoreCase)); }