Sha256: 1f8a1114369066f799477d16154932585ed6174ab18cfc6f969a750f20f77f87

Contents?: true

Size: 446 Bytes

Versions: 13

Compression:

Stored size: 446 Bytes

Contents

module Backup
  class Binder
    ##
    # Creates a new Backup::Notifier::Binder instance. Loops through the provided
    # Hash to set instance variables
    def initialize(key_and_values)
      key_and_values.each do |key, value|
        instance_variable_set("@#{key}", value)
      end
    end

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

Version data entries

13 entries across 13 versions & 4 rubygems

Version Path
backup-5.0.0.beta.3 lib/backup/binder.rb
backedup-5.0.0.beta.5 lib/backup/binder.rb
backedup-5.0.0.beta.4 lib/backup/binder.rb
backedup-5.0.0.beta.3 lib/backup/binder.rb
ext_backup-5.0.0.beta.2.1 lib/backup/binder.rb
ext_backup-5.0.0.beta.2.ext.0.1.2 lib/backup/binder.rb
ext_backup-5.0.0.beta.2.ext.0.1.1 lib/backup/binder.rb
ext_backup-5.0.0.beta.2.ext.0.1.0 lib/backup/binder.rb
backup-5.0.0.beta.2 lib/backup/binder.rb
backup-5.0.0.beta.1 lib/backup/binder.rb
backup-bouchard-4.4.4 lib/backup/binder.rb
backup-bouchard-4.4.2 lib/backup/binder.rb
backup-bouchard-4.4.1 lib/backup/binder.rb