Class: MC2P::RetrieveObjectItemMixin

Inherits:
ObjectItemMixin show all
Defined in:
lib/mixins.rb

Overview

Allows retrieve an object item

Instance Attribute Summary

Attributes inherited from ObjectItemMixin

#_deleted, #json_dict, #resource

Instance Method Summary collapse

Methods inherited from ObjectItemMixin

#id_required_and_not_deleted, #initialize, #to_s

Constructor Details

This class inherits a constructor from MC2P::ObjectItemMixin

Instance Method Details

#retrieveObject

Retrieves the data of the object item



43
44
45
46
47
48
49
# File 'lib/mixins.rb', line 43

def retrieve
  id_required_and_not_deleted
  obj = @resource.detail(
    @json_dict[@id_property]
  )
  @json_dict = obj.json_dict
end