/// <summary> /// Compares the current object with another of type <see cref="ICategoryThemeItem{T}"/>. /// </summary> /// <returns> /// A value, that indicates the relative order of the compared objects. The value has the following meaning: /// <list type="Table"> /// <item>< 0</item><description>This object is less than the <paramref name="other"/>.</description> /// <item>0</item><description>The object is equal</description> /// <item>></item><description>This object is greater than the <paramref name="other"/>.</description> /// </list> /// </returns> /// <param name="other">An Object of type <see cref="ICategoryThemeItem{T}"/> that should be compared with this item.</param> public override int CompareTo(ICategoryThemeItem <T> other) { var o = other as CategoryThemeRangeItem <T>; if (o == null) { return(-1); } if (Matches(o.LowerBound)) { return(0); } if (Matches(o.UpperBound)) { return(0); } return(_lowerBound.CompareTo(o.LowerBound)); }
/// <summary> /// Compares the current object with another of type <see cref="ICategoryThemeItem{T}"/>. /// </summary> /// <returns> /// A value, that indicates the relative order of the compared objects. The value has the following meaning: /// <list type="Table"> /// <item>< 0</item><description>This object is less than the <paramref name="other"/>.</description> /// <item>0</item><description>The object is equal</description> /// <item>></item><description>This object is greater than the <paramref name="other"/>.</description> /// </list> /// Wert Bedeutung Kleiner als 0 (null) Dieses Objekt ist kleiner als der <paramref name="other"/>-Parameter.Zero Dieses Objekt ist gleich <paramref name="other"/>. Größer als 0 (null) Dieses Objekt ist größer als <paramref name="other"/>. /// </returns> /// <param name="other">An Object of type <see cref="ICategoryThemeItem{T}"/> that should be compared with this item.</param> public abstract int CompareTo(ICategoryThemeItem <T> other);
///<summary> ///</summary> ///<param name="cti"></param> public void Add(ICategoryThemeItem <T> cti) { _items.Add(cti); _sorted = false; //this.OnPropertyChanged("Items"); }
/// <summary> /// Compares the current object with another of type <see cref="ICategoryThemeItem{T}"/>. /// </summary> /// <returns> /// A value, that indicates the relative order of the compared objects. The value has the following meaning: /// <list type="Table"> /// <item>< 0</item><description>This object is less than the <paramref name="other"/>.</description> /// <item>0</item><description>The object is equal</description> /// <item>></item><description>This object is greater than the <paramref name="other"/>.</description> /// </list> /// </returns> /// <param name="other">An Object of type <see cref="ICategoryThemeItem{T}"/> that should be compared with this item.</param> public override int CompareTo(ICategoryThemeItem <T> other) { //This does not have a specific order to it return(0); }