Class: Concurrent::Synchronization::Lock

Inherits:
LockableObject
  • Object
show all
Defined in:
lib/concurrent/synchronization/lock.rb

Instance Method Summary collapse

Instance Method Details

#broadcastObject



26
27
28
# File 'lib/concurrent/synchronization/lock.rb', line 26

def broadcast
  synchronize { ns_broadcast }
end

#signalObject



20
21
22
# File 'lib/concurrent/synchronization/lock.rb', line 20

def signal
  synchronize { ns_signal }
end

#wait(timeout = nil) ⇒ Object



8
9
10
# File 'lib/concurrent/synchronization/lock.rb', line 8

def wait(timeout = nil)
  synchronize { ns_wait(timeout) }
end

#wait_until(timeout = nil, &condition) ⇒ Object



14
15
16
# File 'lib/concurrent/synchronization/lock.rb', line 14

def wait_until(timeout = nil, &condition)
  synchronize { ns_wait_until(timeout, &condition) }
end