This gem implements a mutex which allows access to a shared resource as determined by a priority set by each requesting thread. Higher priority values mean higher priority.
Using a PriorityMutex, you can now allow a high priority thread to "jump in line" for a mutex ahead of other lower priority threads. Note, this does not preempt the resource from a thread which is currently using the resource.
License & Notes
The MIT License - Copyright (c) 2015 Mike Jarema