class Mooset::Model

Attributes

endpoint[R]

Public Class Methods

finders(finder_list) click to toggle source
# File lib/mooset/model.rb, line 8
def self.finders(finder_list)
  define_method :finders do
    finder_list
  end
end
new(*args) click to toggle source
Calls superclass method
# File lib/mooset/model.rb, line 14
def initialize(*args)
  hash = args[0] || {}
  @endpoint = hash.delete(:endpoint)

  super(*args)
end

Public Instance Methods

finders() click to toggle source
# File lib/mooset/model.rb, line 25
def finders
  []
end
to_json(*args) click to toggle source
# File lib/mooset/model.rb, line 21
def to_json(*args)
  attributes.to_json
end
to_s() click to toggle source
# File lib/mooset/model.rb, line 29
def to_s
  "#{self.class.name.split('::').last}[#{provider}]"
end