Class: ShelbyArena::Address

Inherits:
ApiObject show all
Defined in:
lib/api/address.rb

Overview

This is a helper class for the person object so the data coming through via Virtus is a hash that has been converted to an array.

Instance Attribute Summary

Attributes inherited from ApiObject

#error_messages, #marked_for_destruction

Instance Method Summary collapse

Methods inherited from ApiObject

#initialize_from_json_object

Constructor Details

#initialize(data) ⇒ Address

Constructor.

Parameters:

  • data

    A hash of data



20
21
22
23
24
# File 'lib/api/address.rb', line 20

def initialize(data)   
  # data[0] is 'Address'
  # data[1] is a Hash of address info to match the attributes above.
  initialize_from_json_object(data[1])       
end