Sha256: 51535e3d29d0fc6dc2bc0fd7398bf143626adecd5bcfbaed7ea14f46567a45a5

Contents?: true

Size: 701 Bytes

Versions: 15

Compression:

Stored size: 701 Bytes

Contents

module Braintree
  class SuccessfulResult
    include BaseModule

    attr_reader :address, :credit_card, :customer, :merchant_account, :payment_method, :settlement_batch_summary, :subscription, :new_transaction, :transaction, :payment_method_nonce, :credentials, :merchant, :supported_networks

    def initialize(attributes = {}) # :nodoc:
      @attrs = attributes.keys
      attributes.each do |key, value|
        instance_variable_set("@#{key}", value)
      end
    end

    def inspect # :nodoc:
      inspected_attributes = @attrs.map { |attr| "#{attr}:#{send(attr).inspect}" }
      "#<#{self.class} #{inspected_attributes.join(" ")}>"
    end

    def success?
      true
    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
braintree-2.66.0 lib/braintree/successful_result.rb
braintree-2.65.0 lib/braintree/successful_result.rb
braintree-2.64.0 lib/braintree/successful_result.rb
braintree-2.63.0 lib/braintree/successful_result.rb
braintree-2.62.0 lib/braintree/successful_result.rb
braintree-2.61.1 lib/braintree/successful_result.rb
braintree-2.61.0 lib/braintree/successful_result.rb
braintree-2.60.0 lib/braintree/successful_result.rb
braintree-2.59.0 lib/braintree/successful_result.rb
braintree-2.58.0 lib/braintree/successful_result.rb
braintree-2.57.0 lib/braintree/successful_result.rb
braintree-2.56.0 lib/braintree/successful_result.rb
braintree-2.55.0 lib/braintree/successful_result.rb
braintree-2.54.0 lib/braintree/successful_result.rb
braintree-2.50.0 lib/braintree/successful_result.rb