Class: ShowDiffJob
- Inherits:
-
Struct
- Object
- Struct
- ShowDiffJob
- Defined in:
- app/jobs/show_diff_job.rb
Instance Attribute Summary collapse
-
#current_tree ⇒ Object
Returns the value of attribute current_tree.
-
#file_name ⇒ Object
Returns the value of attribute file_name.
-
#other_tree ⇒ Object
Returns the value of attribute other_tree.
Instance Method Summary collapse
Instance Attribute Details
#current_tree ⇒ Object
Returns the value of attribute current_tree
1 2 3 |
# File 'app/jobs/show_diff_job.rb', line 1 def current_tree @current_tree end |
#file_name ⇒ Object
Returns the value of attribute file_name
1 2 3 |
# File 'app/jobs/show_diff_job.rb', line 1 def file_name @file_name end |
#other_tree ⇒ Object
Returns the value of attribute other_tree
1 2 3 |
# File 'app/jobs/show_diff_job.rb', line 1 def other_tree @other_tree end |
Instance Method Details
#before ⇒ Object
2 3 4 |
# File 'app/jobs/show_diff_job.rb', line 2 def before Flexite::JobReport.create(file_name: file_name, status: Flexite::JobReport::STATUS[:in_progress]) end |
#error ⇒ Object
16 17 18 19 20 |
# File 'app/jobs/show_diff_job.rb', line 16 def error Flexite::JobReport .find_by_file_name(file_name) .update_attributes(status: Flexite::JobReport::STATUS[:error]) end |
#perform ⇒ Object
6 7 8 |
# File 'app/jobs/show_diff_job.rb', line 6 def perform Flexite::Diff::CheckService.new(current_tree, other_tree, file_name).call end |