class ChefApply::StatusReporter
Public Class Methods
new(ui_element, prefix: nil, key: nil)
click to toggle source
# File lib/chef_apply/status_reporter.rb, line 21 def initialize(ui_element, prefix: nil, key: nil) @ui_element = ui_element @key = key @ui_element.update(prefix: prefix) end
Public Instance Methods
error(msg)
click to toggle source
# File lib/chef_apply/status_reporter.rb, line 36 def error(msg) update(msg) @ui_element.error end
success(msg)
click to toggle source
# File lib/chef_apply/status_reporter.rb, line 31 def success(msg) update(msg) @ui_element.success end
update(msg)
click to toggle source
# File lib/chef_apply/status_reporter.rb, line 27 def update(msg) @ui_element.update({ @key => msg }) end