Esempio n. 1
0
        OrderedSequence <T, V> PushLeft(OrderedElement <T, V> o)
        {
            var v = _finger.LeftView();

            if (v != null)
            {
                if (v.End.Measure().CompareTo(o.Measure()) < 0)
                {
                    throw new Exception("OrderedSequence Error: PushLeft() of an element greater than the smallest seq el.");
                }
            }

            return(new OrderedSequence <T, V>(_x, _finger.PushLeft(o)));
        }
Esempio n. 2
0
 public override FingerTree <WeightedElement <T>, double> PushLeft(WeightedElement <T> t) => new PriorityQueue <T>(_finger.PushLeft(t));
Esempio n. 3
0
 public override FingerTree <SizedElement <T>, int> PushLeft(SizedElement <T> t) => new FingerArray <T>(_finger.PushLeft(t));