Sha256: e2911c8d17d2ca425a6fcaab55f1da0eee492258233e5142a3a0c479ac7d0db0

Contents?: true

Size: 716 Bytes

Versions: 20

Compression:

Stored size: 716 Bytes

Contents

module Braintree
  class Merchant
    include BaseModule # :nodoc:

    attr_reader :id, :email, :company_name, :country_code_alpha2, :country_code_alpha3, :country_code_numeric, :country_name, :merchant_accounts

    def initialize(attributes) # :nodoc:
      @merchant_accounts = attributes.delete(:merchant_accounts).map do |merchant_account|
        MerchantAccount._new(Configuration.gateway, merchant_account)
      end

      set_instance_variables_from_hash(attributes)
    end

    class << self
      protected :new
    end

    def self._new(*args) # :nodoc:
      self.new *args
    end

    def self.provision_raw_apple_pay
      Configuration.gateway.merchant.provision_raw_apple_pay
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
braintree-2.75.0 lib/braintree/merchant.rb
braintree-2.74.0 lib/braintree/merchant.rb
braintree-2.73.0 lib/braintree/merchant.rb
braintree-2.72.0 lib/braintree/merchant.rb
braintree-2.71.0 lib/braintree/merchant.rb
braintree-2.70.0 lib/braintree/merchant.rb
braintree-2.69.1 lib/braintree/merchant.rb
braintree-2.69.0 lib/braintree/merchant.rb
braintree-2.68.2 lib/braintree/merchant.rb
braintree-2.68.1 lib/braintree/merchant.rb
braintree-2.68.0 lib/braintree/merchant.rb
braintree-2.67.0 lib/braintree/merchant.rb
braintree-2.66.0 lib/braintree/merchant.rb
braintree-2.65.0 lib/braintree/merchant.rb
braintree-2.64.0 lib/braintree/merchant.rb
braintree-2.63.0 lib/braintree/merchant.rb
braintree-2.62.0 lib/braintree/merchant.rb
braintree-2.61.1 lib/braintree/merchant.rb
braintree-2.61.0 lib/braintree/merchant.rb
braintree-2.60.0 lib/braintree/merchant.rb