Sha256: ca44ef1b47c25cb302c54ce0b0c9dca54cfdbbb8c5109db1431b88077779605d

Contents?: true

Size: 825 Bytes

Versions: 25

Compression:

Stored size: 825 Bytes

Contents

module Braintree
  class CoinbaseAccount
    include BaseModule # :nodoc:

    attr_reader :created_at
    attr_reader :customer_id
    attr_reader :default
    attr_reader :subscriptions
    attr_reader :token
    attr_reader :updated_at
    attr_reader :user_email
    attr_reader :user_id
    attr_reader :user_name

    def initialize(gateway, attributes) # :nodoc:
      @gateway = gateway
      set_instance_variables_from_hash(attributes)
      @subscriptions = (@subscriptions || []).map { |subscription_hash| Subscription._new(@gateway, subscription_hash) }
    end

    class << self
      protected :new
    end

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

    # Returns true if this coinbase account is the customer's default payment method.
    def default?
      @default
    end
  end
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
braintree-2.104.1 lib/braintree/coinbase_account.rb
braintree-2.104.0 lib/braintree/coinbase_account.rb
braintree-2.103.0 lib/braintree/coinbase_account.rb
braintree-2.102.0 lib/braintree/coinbase_account.rb
braintree-2.101.0 lib/braintree/coinbase_account.rb
braintree-2.100.0 lib/braintree/coinbase_account.rb
braintree-2.99.0 lib/braintree/coinbase_account.rb
braintree-2.98.0 lib/braintree/coinbase_account.rb
braintree-2.97.0 lib/braintree/coinbase_account.rb
braintree-2.96.0 lib/braintree/coinbase_account.rb
braintree-2.95.0 lib/braintree/coinbase_account.rb
braintree-2.94.0 lib/braintree/coinbase_account.rb
braintree-2.93.0 lib/braintree/coinbase_account.rb
braintree-2.92.0 lib/braintree/coinbase_account.rb
braintree-2.91.0 lib/braintree/coinbase_account.rb
braintree-2.90.0 lib/braintree/coinbase_account.rb
braintree-2.89.0 lib/braintree/coinbase_account.rb
braintree-2.88.0 lib/braintree/coinbase_account.rb
braintree-2.87.0 lib/braintree/coinbase_account.rb
braintree-2.86.0 lib/braintree/coinbase_account.rb