Class: Rbgo::CoRun::Scheduler

Inherits:
Object
  • Object
show all
Includes:
Singleton
Defined in:
lib/rbgo/corun.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#num_threadObject

Returns the value of attribute num_thread.



41
42
43
# File 'lib/rbgo/corun.rb', line 41

def num_thread
  @num_thread
end

Instance Method Details

#schedule(routine) ⇒ Object



178
179
180
181
# File 'lib/rbgo/corun.rb', line 178

def schedule(routine)
  task_queue << routine
  nil
end