Exemple #1
0
 /// <summary>
 /// Inserts all specified priority-value pairs into the queue.
 /// </summary>
 /// <param name="priorityValuePairs">The priority-value pairs.</param>
 /// <remarks>O(log max(n, m)), where m is the number of values in
 /// <paramref name="priorityValuePairs"/>.</remarks>
 public PriorityQueue <T, TPriority> InsertRange(IEnumerable <PriorityValuePair <T, TPriority> > priorityValuePairs)
 {
     return(new PriorityQueue <T, TPriority>(_ft.InsertRange(priorityValuePairs)));
 }
Exemple #2
0
 /// <summary>
 /// Inserts all specified items into the sequence.
 /// </summary>
 /// <param name="items">The items.</param>
 /// <remarks>O(log max(n, m)), where m is the number of elements in
 /// <paramref name="items"/>.</remarks>
 public OrderedSequence <T> InsertRange(IEnumerable <T> items)
 {
     return(new OrderedSequence <T>(_ft.InsertRange(items.Select(t => new Element(t)))));
 }