Sha256: 8058d34a956191365de5971af71a9781e5ce8d5499124c979eccc340a720c89f

Contents?: true

Size: 348 Bytes

Versions: 2

Compression:

Stored size: 348 Bytes

Contents

require 'active_support/core_ext/string/inflections'

module Lol
  class Model
    # Initializes a Lol::Model
    # @param options [Hash]
    # @return [Lol::Model]
    def initialize options = {}
      @raw = options
      options.each do |attribute_name, value|
        send "#{attribute_name.to_s.underscore}=", value
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
ruby-lol-0.0.2 lib/lol/model.rb
ruby-lol-0.0.1 lib/lol/model.rb