Module: ONEAccess::Serializable
- Included in:
- Response::OrganizationsResponse, Response::ProductGroupsResponse, Response::ResearchDocumentResponse, Response::UserResponse
- Defined in:
- lib/oneaccess/serializable.rb
Instance Method Summary collapse
Instance Method Details
#from_json(json) ⇒ Object
8 9 10 11 12 |
# File 'lib/oneaccess/serializable.rb', line 8 def from_json(json) obj = new @representer_class.new(obj).from_json(json) obj end |
#represented_by(representer_class) ⇒ Object
4 5 6 |
# File 'lib/oneaccess/serializable.rb', line 4 def represented_by(representer_class) @representer_class = representer_class end |