Class: Dnsimple::Struct::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/dnsimple/struct.rb

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ Base

Returns a new instance of Base.


7
8
9
10
11
12
# File 'lib/dnsimple/struct.rb', line 7

def initialize(attributes = {})
  attributes.each do |key, value|
    m = "#{key}=".to_sym
    send(m, value) if respond_to?(m)
  end
end