Class: Backup::Binder

Inherits:
Object
  • Object
show all
Defined in:
lib/backup/binder.rb

Instance Method Summary collapse

Constructor Details

#initialize(key_and_values) ⇒ Binder

Creates a new Backup::Notifier::Binder instance. Loops through the provided Hash to set instance variables



9
10
11
12
13
# File 'lib/backup/binder.rb', line 9

def initialize(key_and_values)
  key_and_values.each do |key, value|
    instance_variable_set("@#{ key }", value)
  end
end

Instance Method Details

#get_bindingObject

Returns the binding (needs a wrapper method because #binding is a private method)



17
18
19
# File 'lib/backup/binder.rb', line 17

def get_binding
  binding
end