Class: EventQ::WorkerProcess
- Inherits:
-
Object
- Object
- EventQ::WorkerProcess
- Defined in:
- lib/eventq/worker_status.rb
Overview
Class that is used to represent a process and its associated threads.
Instance Attribute Summary collapse
-
#pid ⇒ Object
Returns the value of attribute pid.
-
#threads ⇒ Object
readonly
Returns the value of attribute threads.
Instance Method Summary collapse
-
#initialize(pid) ⇒ WorkerProcess
constructor
A new instance of WorkerProcess.
Constructor Details
#initialize(pid) ⇒ WorkerProcess
Returns a new instance of WorkerProcess.
49 50 51 52 |
# File 'lib/eventq/worker_status.rb', line 49 def initialize(pid) self.pid = pid @threads = Concurrent::Array.new end |
Instance Attribute Details
#pid ⇒ Object
Returns the value of attribute pid.
47 48 49 |
# File 'lib/eventq/worker_status.rb', line 47 def pid @pid end |
#threads ⇒ Object (readonly)
Returns the value of attribute threads.
48 49 50 |
# File 'lib/eventq/worker_status.rb', line 48 def threads @threads end |