System.Threading.Monitor.Monitor_pulse C# (CSharp) Method

Monitor_pulse() private method

private Monitor_pulse ( object obj ) : void
obj object
return void
		private extern static void Monitor_pulse(object obj);

Usage Example

示例#1
0
 /// <summary>Notifies a thread in the waiting queue of a change in the locked object's state.</summary>
 /// <param name="obj">The object a thread is waiting for. </param>
 /// <exception cref="T:System.ArgumentNullException">The <paramref name="obj" /> parameter is null. </exception>
 /// <exception cref="T:System.Threading.SynchronizationLockException">The calling thread does not own the lock for the specified object. </exception>
 /// <filterpriority>1</filterpriority>
 public static void Pulse(object obj)
 {
     if (obj == null)
     {
         throw new ArgumentNullException("obj");
     }
     if (!Monitor.Monitor_test_synchronised(obj))
     {
         throw new SynchronizationLockException("Object is not synchronized");
     }
     Monitor.Monitor_pulse(obj);
 }