Class: Io::Flow::V0::Models::CheckoutUrls

Inherits:
Object
  • Object
show all
Defined in:
lib/flow_commerce/flow_api_v0_client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(incoming = {}) ⇒ CheckoutUrls

Returns a new instance of CheckoutUrls.



36278
36279
36280
36281
36282
36283
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 36278

def initialize(incoming={})
  opts = HttpClient::Helper.symbolize_keys(incoming)
  @continue_shopping = (x = opts.delete(:continue_shopping); x.nil? ? nil : HttpClient::Preconditions.assert_class('continue_shopping', x, String))
  @confirmation = (x = opts.delete(:confirmation); x.nil? ? nil : HttpClient::Preconditions.assert_class('confirmation', x, String))
  @invalid_checkout = (x = opts.delete(:invalid_checkout); x.nil? ? nil : HttpClient::Preconditions.assert_class('invalid_checkout', x, String))
end

Instance Attribute Details

#confirmationObject (readonly)

Returns the value of attribute confirmation.



36276
36277
36278
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 36276

def confirmation
  @confirmation
end

#continue_shoppingObject (readonly)

Returns the value of attribute continue_shopping.



36276
36277
36278
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 36276

def continue_shopping
  @continue_shopping
end

#invalid_checkoutObject (readonly)

Returns the value of attribute invalid_checkout.



36276
36277
36278
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 36276

def invalid_checkout
  @invalid_checkout
end

Instance Method Details

#copy(incoming = {}) ⇒ Object



36289
36290
36291
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 36289

def copy(incoming={})
  CheckoutUrls.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
end

#to_hashObject



36293
36294
36295
36296
36297
36298
36299
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 36293

def to_hash
  {
    :continue_shopping => continue_shopping,
    :confirmation => confirmation,
    :invalid_checkout => invalid_checkout
  }
end

#to_jsonObject



36285
36286
36287
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 36285

def to_json
  JSON.dump(to_hash)
end