Search Results for

    Show / Hide Table of Contents

    Interface IUpdatablePriorityQueue<T>

    An IPriorityQueue<T> which supports priority update and item removal.

    Inherited Members
    IPriorityQueue<T>.Push(T, Int32)
    IPriorityQueue<T>.Pop()
    IPriorityQueue<T>.Count
    IPriorityQueue<T>.Peek()
    Namespace: MoreStructures.PriorityQueues
    Assembly: MoreStructures.dll
    Syntax
    public interface IUpdatablePriorityQueue<T> : IPriorityQueue<T>
    Type Parameters
    Name Description
    T

    Methods

    | Improve this Doc View Source

    GetPrioritiesOf(T)

    Returns all the priorities with which item is registered in the queue, sorted by highest to smallest.

    Declaration
    IEnumerable<int> GetPrioritiesOf(T item)
    Parameters
    Type Name Description
    T item

    The item, to retrieve priorities of.

    Returns
    Type Description
    IEnumerable<System.Int32>

    The sequence of System.Int32 values, each being a priority.

    | Improve this Doc View Source

    Remove(T)

    Removes the first occurrence of the provided item from the queue.

    Declaration
    PrioritizedItem<T>? Remove(T item)
    Parameters
    Type Name Description
    T item

    The item to be removed.

    Returns
    Type Description
    System.Nullable<MoreStructures.PriorityQueues.PrioritizedItem<T>>

    The MoreStructures.PriorityQueues.PrioritizedItem<T> with which item was present in the queue, before being removed, or null, if no occurrence of item was found.

    | Improve this Doc View Source

    UpdatePriority(T, Int32)

    Updates the priority of the provided item, without changing the timestamp.

    Declaration
    PrioritizedItem<T> UpdatePriority(T item, int newPriority)
    Parameters
    Type Name Description
    T item

    The item, to update the priority of. Must be present in the queue.

    System.Int32 newPriority

    The new priority to be assigned to item.

    Returns
    Type Description
    MoreStructures.PriorityQueues.PrioritizedItem<T>

    The MoreStructures.PriorityQueues.PrioritizedItem<T> with which item was present in the queue, before being updated.

    Extension Methods

    SuffixStructureNodeExtensions.GetAllSuffixesFor<TEdge, TNode>(TNode, TextWithTerminator)
    UpdatablePriorityQueueExtensions.PushOrUpdate<T>(IUpdatablePriorityQueue<T>, T, Int32)
    UpdatablePriorityQueueExtensions.PopAll<T>(IPriorityQueue<T>)
    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX