Esempio n. 1
0
 public IOrderableNotifyEnumerable <T> AsNotifiable()
 {
     if (notifyEnumerable == null)
     {
         notifyEnumerable = Source.AsNotifiable().ThenBy(Predicate, Comparer);
     }
     return(notifyEnumerable);
 }
Esempio n. 2
0
        public ObservableThenBy(IOrderableNotifyEnumerable <TItem> source, ObservingFunc <TItem, TKey> keySelector, IComparer <TKey> comparer)
        {
            if (source == null)
            {
                throw new ArgumentNullException("source");
            }
            if (keySelector == null)
            {
                throw new ArgumentNullException("keySelector");
            }

            this.source      = source;
            this.keySelector = keySelector;
            this.comparer    = comparer;
        }
Esempio n. 3
0
        public ObservableThenBy(IOrderableNotifyEnumerable <TItem> source, ObservingFunc <TItem, TKey> keySelector, IComparer <TKey> comparer)
        {
            if (source == null)
            {
                throw new ArgumentNullException("source");
            }
            if (keySelector == null)
            {
                throw new ArgumentNullException("keySelector");
            }

            this.source      = source;
            this.keySelector = keySelector;
            this.comparer    = comparer;
            manualNotifier   = new ManualObservableCollectionView <IEnumerable <TItem> >(SL.SelectMany(source.Sequences,
                                                                                                       sequence => searchTrees[sequence].Values));

            Attach();
        }
Esempio n. 4
0
 public static IOrderableNotifyEnumerable <TItem> ThenByDescendingWithComparer <TItem, TKey>(IOrderableNotifyEnumerable <TItem> source, ObservingFunc <TItem, TKey> keySelector, IComparer <TKey> comparer)
 {
     return(new ObservableThenBy <TItem, TKey>(source, keySelector, new ReverseComparer <TKey>(comparer)));
 }
Esempio n. 5
0
 public static IOrderableNotifyEnumerable <TItem> ThenByDescending <TItem, TKey>(IOrderableNotifyEnumerable <TItem> source, ObservingFunc <TItem, TKey> keySelector)
 {
     return(ThenByDescendingWithComparer(source, keySelector, null));
 }