Skip to content
BlueRaja edited this page Jan 29, 2016 · 17 revisions

Adding the Priority Queue to your project

Method 1: NuGet (recommended)
  1. Right-click your project in Visual Studio and choose "Manage NuGet Packages".
  2. Under 'Browse', search for OptimizedPriorityQueue, then click 'Install'.
  3. Remember to add using Priority_Queue; to the top of any classes you want to use it from.
Method 2: Clone the repo
  1. Clone the repo using git.
  2. Add Priority Queue/Priority Queue.csproj to your solution.
  3. Reference the Priority Queue project from any projects you want to use it from.
  4. Remember to add using Priority_Queue; to the top of any classes you want to use it from.

Which implementation should I use?

This project comes with two IPriorityQueue implementations:

  • SimplePriorityQueue is thread-safe, contains safety checks, and is easy-to-use.
  • FastPriorityQueue is less convenient and safe, but has been optimized to be as absolutely fast as possible.

Click the above links to learn how to use each one.

Clone this wiki locally