Class that implements windows safe multi-threaded applications