Class: ActiveJob::ConfiguredJob
- Inherits:
 - 
      Object
      
        
- Object
 - ActiveJob::ConfiguredJob
 
 
- Defined in:
 - lib/active_job/configured_job.rb
 
Overview
:nodoc:
Instance Method Summary collapse
- 
  
    
      #initialize(job_class, options = {})  ⇒ ConfiguredJob 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    
A new instance of ConfiguredJob.
 - #perform_later(*args) ⇒ Object
 - #perform_now(*args) ⇒ Object
 
Constructor Details
#initialize(job_class, options = {}) ⇒ ConfiguredJob
Returns a new instance of ConfiguredJob.
      5 6 7 8  | 
    
      # File 'lib/active_job/configured_job.rb', line 5 def initialize(job_class, = {}) @options = @job_class = job_class end  | 
  
Instance Method Details
#perform_later(*args) ⇒ Object
      15 16 17  | 
    
      # File 'lib/active_job/configured_job.rb', line 15 def perform_later(*args) @job_class.new(*args).enqueue @options end  | 
  
#perform_now(*args) ⇒ Object
      10 11 12  | 
    
      # File 'lib/active_job/configured_job.rb', line 10 def perform_now(*args) @job_class.new(*args).perform_now end  |