Thursday, May 16, 2013

Spinning

...as opposed to blocking in threading is the art of holding a thread from progressing by way of a loop which will eventually expire instead of freezing up the thread with code that is actual of threading itself. I am reading C# 4.0 in a Nutshell by Ben and Joseph Albahari and this is something I read of today. At this training I was encouraged to make WatiN tests pause for aesthetics not by Thread.Sleep but instead by setting a DateTime variable and then running a loop until the moment at hand was greater than that in the variable.

No comments:

Post a Comment