Sha256: 392b7964d49128e458f59c529315f4bce3dd158eda62caaef7c073277805f358
Contents?: true
Size: 421 Bytes
Versions: 14
Compression:
Stored size: 421 Bytes
Contents
module RevealCK module Commands # Utility that wakes up a thread periodically class ThreadWaker def initialize(thread_to_wake, wait_period = 1) @thread_to_wake = thread_to_wake @wait_period = wait_period end def run Thread.new do loop do sleep @wait_period @thread_to_wake.wakeup end end end end end end
Version data entries
14 entries across 14 versions & 1 rubygems