Class: Gonebusy::UpdateBookingByIdResponse
- Defined in:
- lib/gonebusy/models/update_booking_by_id_response.rb
Instance Attribute Summary collapse
-
#booking ⇒ EntitiesBookingResponse
TODO: Write general description for this method.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
Instance Method Summary collapse
-
#initialize(booking = nil) ⇒ UpdateBookingByIdResponse
constructor
A new instance of UpdateBookingByIdResponse.
Methods inherited from BaseModel
Constructor Details
#initialize(booking = nil) ⇒ UpdateBookingByIdResponse
Returns a new instance of UpdateBookingByIdResponse.
18 19 20 |
# File 'lib/gonebusy/models/update_booking_by_id_response.rb', line 18 def initialize(booking = nil) @booking = booking end |
Instance Attribute Details
#booking ⇒ EntitiesBookingResponse
TODO: Write general description for this method
7 8 9 |
# File 'lib/gonebusy/models/update_booking_by_id_response.rb', line 7 def booking @booking end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash
23 24 25 26 27 28 29 30 31 |
# File 'lib/gonebusy/models/update_booking_by_id_response.rb', line 23 def self.from_hash(hash) return nil unless hash # Extract variables from the hash booking = EntitiesBookingResponse.from_hash(hash['booking']) if hash['booking'] # Create object from extracted values UpdateBookingByIdResponse.new(booking) end |
.names ⇒ Object
A mapping from model property names to API property names
10 11 12 13 14 15 16 |
# File 'lib/gonebusy/models/update_booking_by_id_response.rb', line 10 def self.names if @_hash.nil? @_hash = {} @_hash["booking"] = "booking" end @_hash end |