Class: Remi::Loader::SubJob

Inherits:
Remi::Loader show all
Defined in:
lib/remi/data_subjects/sub_job.rb

Instance Attribute Summary collapse

Attributes inherited from Remi::Loader

#logger

Instance Method Summary collapse

Constructor Details

#initialize(*args, **kargs, &block) ⇒ SubJob

Returns a new instance of SubJob.

Parameters:

  • sub_job (Object)

    The name (relative to parent job) of the subjob to use

  • data_subject (Symbol)

    The name (relatvie to the sub job) of the sub job's data frame



29
30
31
32
# File 'lib/remi/data_subjects/sub_job.rb', line 29

def initialize(*args, **kargs, &block)
  super
  init_sub_job_loader(*args, **kargs, &block)
end

Instance Attribute Details

#data_subjectObject

Returns the value of attribute data_subject.



34
35
36
# File 'lib/remi/data_subjects/sub_job.rb', line 34

def data_subject
  @data_subject
end

#sub_jobObject

Returns the value of attribute sub_job.



34
35
36
# File 'lib/remi/data_subjects/sub_job.rb', line 34

def sub_job
  @sub_job
end

Instance Method Details

#load(data_frame) ⇒ true

Returns On success.

Parameters:

  • data_frame (Object)

    Data frame to load to target sub job data subject

Returns:

  • (true)

    On success



38
39
40
41
# File 'lib/remi/data_subjects/sub_job.rb', line 38

def load(data_frame)
  sub_job.job.send(data_subject).df = data_frame
  true
end