Class: Io::Flow::V0::Models::PaymentMethodDataOptionLogoSvg

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

Instance Attribute Summary collapse

Attributes inherited from PaymentMethodDataOptionLogo

#type

Instance Method Summary collapse

Methods inherited from PaymentMethodDataOptionLogo

from_json, #to_hash

Constructor Details

#initialize(incoming = {}) ⇒ PaymentMethodDataOptionLogoSvg

Returns a new instance of PaymentMethodDataOptionLogoSvg.



57603
57604
57605
57606
57607
57608
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 57603

def initialize(incoming={})
  super(:type => PaymentMethodDataOptionLogo::Types::PAYMENT_METHOD_DATA_OPTION_LOGO_SVG)
  opts = HttpClient::Helper.symbolize_keys(incoming)
  HttpClient::Preconditions.require_keys(opts, [:url], 'PaymentMethodDataOptionLogoSvg')
  @url = HttpClient::Preconditions.assert_class('url', opts.delete(:url), String)
end

Instance Attribute Details

#urlObject (readonly)

Returns the value of attribute url.



57601
57602
57603
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 57601

def url
  @url
end

Instance Method Details

#copy(incoming = {}) ⇒ Object



57614
57615
57616
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 57614

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

#subtype_to_hashObject



57618
57619
57620
57621
57622
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 57618

def subtype_to_hash
  {
    :url => url
  }
end

#to_jsonObject



57610
57611
57612
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 57610

def to_json
  JSON.dump(to_hash)
end