Обновить

Комментарии 4

You need to know how to control interaction between threads in order to get the most out of this power.
spanish dictionary

do you know how I can programmatically limit threads number to 1 for debug?

I have used SemaphoreSlim class for such purpuses.

private readonly SemaphoreSlim syncObject = new SemaphoreSlim(1);
...
      syncObject.Wait();
      try {
        // CODE YOU WANT TO DEBUG
      }
      finally {
        syncObject.Release();
      }
Зарегистрируйтесь на Хабре, чтобы оставить комментарий

Публикации