Are c# timers naturally multithreaded?

后端 未结 3 2003
时光说笑
时光说笑 2020-12-19 22:21

If I have two system timers firing events at 10 and 20s respectively, are the calls to the event functions multithreaded? In the scenario below, I have timers that fire even

3条回答
  •  甜味超标
    2020-12-19 23:07

    Looks like it won't block if you use System.Threading.Timer or invoke System.Timers.Timer without a SynchronizingObject.

    Similar question: Do C# Timers elapse on a separate thread?

提交回复
热议问题