Setting the loop() function of JobThread to private.
Setting std::thread as a friend of JobThread so it can access loop().