module Oshpark::RemoteModel::ClassMethods
Public Instance Methods
all()
click to toggle source
# File lib/oshpark/remote_model.rb, line 30 def all Oshpark::client.public_send(object_names)[object_names].map do |json| self.from_json json end end
find(id)
click to toggle source
# File lib/oshpark/remote_model.rb, line 36 def find id self.from_json(Oshpark::client.public_send(object_name, id)[object_name]) end