Class: Worldline::Connect::SDK::V1::Domain::Merchant
- Inherits:
-
Domain::DataObject
- Object
- Domain::DataObject
- Worldline::Connect::SDK::V1::Domain::Merchant
- Defined in:
- lib/worldline/connect/sdk/v1/domain/merchant.rb
Instance Attribute Summary collapse
-
#configuration_id ⇒ String
The current value of configuration_id.
-
#contact_website_url ⇒ String
The current value of contact_website_url.
-
#seller ⇒ Worldline::Connect::SDK::V1::Domain::Seller
The current value of seller.
-
#website_url ⇒ String
The current value of website_url.
Instance Method Summary collapse
Methods inherited from Domain::DataObject
Instance Attribute Details
#configuration_id ⇒ String
Returns the current value of configuration_id.
17 18 19 |
# File 'lib/worldline/connect/sdk/v1/domain/merchant.rb', line 17 def configuration_id @configuration_id end |
#contact_website_url ⇒ String
Returns the current value of contact_website_url.
17 18 19 |
# File 'lib/worldline/connect/sdk/v1/domain/merchant.rb', line 17 def contact_website_url @contact_website_url end |
#seller ⇒ Worldline::Connect::SDK::V1::Domain::Seller
Returns the current value of seller.
17 18 19 |
# File 'lib/worldline/connect/sdk/v1/domain/merchant.rb', line 17 def seller @seller end |
#website_url ⇒ String
Returns the current value of website_url.
17 18 19 |
# File 'lib/worldline/connect/sdk/v1/domain/merchant.rb', line 17 def website_url @website_url end |
Instance Method Details
#from_hash(hash) ⇒ Object
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/worldline/connect/sdk/v1/domain/merchant.rb', line 37 def from_hash(hash) super if hash.has_key? 'configurationId' @configuration_id = hash['configurationId'] end if hash.has_key? 'contactWebsiteUrl' @contact_website_url = hash['contactWebsiteUrl'] end if hash.has_key? 'seller' raise TypeError, "value '%s' is not a Hash" % [hash['seller']] unless hash['seller'].is_a? Hash @seller = Worldline::Connect::SDK::V1::Domain::Seller.new_from_hash(hash['seller']) end if hash.has_key? 'websiteUrl' @website_url = hash['websiteUrl'] end end |
#to_h ⇒ Hash
28 29 30 31 32 33 34 35 |
# File 'lib/worldline/connect/sdk/v1/domain/merchant.rb', line 28 def to_h hash = super hash['configurationId'] = @configuration_id unless @configuration_id.nil? hash['contactWebsiteUrl'] = @contact_website_url unless @contact_website_url.nil? hash['seller'] = @seller.to_h unless @seller.nil? hash['websiteUrl'] = @website_url unless @website_url.nil? hash end |