The WorkQueue allow other threads to submit tasks to be executed in the thread that the WorkQueue lives on. The WorkQueue will cancel all the pending tasks when it gets destructed, to make sure the tasks won't get called with invalid references.