Refactor SlmQueue to handle more queueing systems

This is a first draft of some interfaces. (sorry I kept the old code for now to help me, so the files changed is a bit messy).