Class: Simrpc::ThreadPoolJob

Inherits:
Object
  • Object
show all
Defined in:
lib/simrpc/thread_pool.rb

Overview

Work item to be executed in thread pool

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(*params, &block) ⇒ ThreadPoolJob

Returns a new instance of ThreadPoolJob.



35
36
37
38
# File 'lib/simrpc/thread_pool.rb', line 35

def initialize(*params, &block)
  @params = params
  @handler = block
end

Instance Attribute Details

#handlerObject

Returns the value of attribute handler.



32
33
34
# File 'lib/simrpc/thread_pool.rb', line 32

def handler
  @handler
end

#paramsObject

Returns the value of attribute params.



33
34
35
# File 'lib/simrpc/thread_pool.rb', line 33

def params
  @params
end