Method: ReservedNames::Win32::Mutex#test

Defined in:
lib/chef/win32/mutex.rb

#testObject

Attempts to grab the mutex. Returns true if the mutex is grabbed or if it’s already owned; false otherwise.



39
40
41
# File 'lib/chef/win32/mutex.rb', line 39

def test
  WaitForSingleObject(handle, 0) == WAIT_OBJECT_0
end