class Activite::Base
Attributes
attrs[R]
@return [Hash]
Public Class Methods
new(attrs = {})
click to toggle source
Initializes a new object with attributes for the values passed to the constructor.
@param attrs [Hash] @return [Activite::Base]
# File lib/activite/base.rb, line 10 def initialize(attrs = {}) @attrs = attrs || {} @attrs.each do |key, value| self.class.class_eval { attr_reader key } instance_variable_set("@#{key}", value) end end