Class: OnlinePayments::SDK::Domain::MarketPlace

Inherits:
DataObject
  • Object
show all
Defined in:
lib/onlinepayments/sdk/domain/market_place.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from DataObject

new_from_hash

Instance Attribute Details

#retailer_countryString

Returns the current value of retailer_country.

Returns:

  • (String)

    the current value of retailer_country



11
12
13
# File 'lib/onlinepayments/sdk/domain/market_place.rb', line 11

def retailer_country
  @retailer_country
end

#retailer_nameString

Returns the current value of retailer_name.

Returns:

  • (String)

    the current value of retailer_name



11
12
13
# File 'lib/onlinepayments/sdk/domain/market_place.rb', line 11

def retailer_name
  @retailer_name
end

Instance Method Details

#from_hash(hash) ⇒ Object



25
26
27
28
29
30
31
32
33
# File 'lib/onlinepayments/sdk/domain/market_place.rb', line 25

def from_hash(hash)
  super
  if hash.has_key? 'retailerCountry'
    @retailer_country = hash['retailerCountry']
  end
  if hash.has_key? 'retailerName'
    @retailer_name = hash['retailerName']
  end
end

#to_hHash

Returns:

  • (Hash)


18
19
20
21
22
23
# File 'lib/onlinepayments/sdk/domain/market_place.rb', line 18

def to_h
  hash = super
  hash['retailerCountry'] = @retailer_country unless @retailer_country.nil?
  hash['retailerName'] = @retailer_name unless @retailer_name.nil?
  hash
end