Do I need to call Close() on a ManualResetEvent?

前端 未结 6 939
伪装坚强ぢ
伪装坚强ぢ 2020-12-10 11:43

I\'ve been reading up on .NET Threading and was working on some code that uses a ManualResetEvent. I have found lots of code samples on the internet. However, when reading

6条回答
  •  轻奢々
    轻奢々 (楼主)
    2020-12-10 12:29

    The Close is handled inside ManualResetEvent's Dispose, and that's called by the 'using' statement.

    http://msdn.microsoft.com/en-us/library/yh598w02%28VS.100%29.aspx

提交回复
热议问题