Class: Bootsnap::CLI::WorkerPool::Inline
- Inherits:
-
Object
- Object
- Bootsnap::CLI::WorkerPool::Inline
- Defined in:
- lib/bootsnap/cli/worker_pool.rb
Instance Method Summary collapse
-
#initialize(jobs: {}) ⇒ Inline
constructor
A new instance of Inline.
- #push(job, *args) ⇒ Object
- #shutdown ⇒ Object
- #spawn ⇒ Object
Constructor Details
#initialize(jobs: {}) ⇒ Inline
Returns a new instance of Inline.
17 18 19 |
# File 'lib/bootsnap/cli/worker_pool.rb', line 17 def initialize(jobs: {}) @jobs = jobs end |
Instance Method Details
#push(job, *args) ⇒ Object
21 22 23 24 |
# File 'lib/bootsnap/cli/worker_pool.rb', line 21 def push(job, *args) @jobs.fetch(job).call(*args) nil end |
#shutdown ⇒ Object
30 31 32 |
# File 'lib/bootsnap/cli/worker_pool.rb', line 30 def shutdown # noop end |
#spawn ⇒ Object
26 27 28 |
# File 'lib/bootsnap/cli/worker_pool.rb', line 26 def spawn # noop end |