class Passfort::Resource::Base

Public Class Methods

attributes(*keys) click to toggle source
# File lib/passfort/resource/base.rb, line 8
def self.attributes(*keys)
  keys.each { |key| define_method(key) { @attributes[key] } }
end
new(attributes) click to toggle source
# File lib/passfort/resource/base.rb, line 12
def initialize(attributes)
  @attributes = attributes.with_indifferent_access
end

Public Instance Methods

to_h() click to toggle source
# File lib/passfort/resource/base.rb, line 16
def to_h
  @attributes
end