Sha256: 127ea3fc308502f9edb688cd978a6b498e3f39faa3b5541596bc58688580a915
Contents?: true
Size: 507 Bytes
Versions: 4
Compression:
Stored size: 507 Bytes
Contents
module Shipcloud module Operations module Find module ClassMethods # Finds a given object # # @param [String] id The id of the object that should be found # @return [Shipcloud::Base] The found object def find(id) response = Shipcloud.request(:get, "#{self.name.split("::").last.downcase}s/#{id}", {}) self.new(response) end end def self.included(base) base.extend(ClassMethods) end end end end
Version data entries
4 entries across 4 versions & 1 rubygems