Sha256: 876a41c08fdc5389f27a6ea5c8c7f95e677ff2252eb94d479533817819771d37

Contents?: true

Size: 834 Bytes

Versions: 120

Compression:

Stored size: 834 Bytes

Contents

module ActiveMerchant #:nodoc:
  module Billing #:nodoc:
  
    class Error < ActiveMerchantError #:nodoc:
    end
  
    class Response
      attr_reader :params, :message, :test, :authorization, :avs_result, :cvv_result
      
      def success?
        @success
      end

      def test?
        @test
      end
      
      def fraud_review?
        @fraud_review
      end
      
      def initialize(success, message, params = {}, options = {})
        @success, @message, @params = success, message, params.stringify_keys
        @test = options[:test] || false        
        @authorization = options[:authorization]
        @fraud_review = options[:fraud_review]
        @avs_result = AVSResult.new(options[:avs_result]).to_hash
        @cvv_result = CVVResult.new(options[:cvv_result]).to_hash
      end
    end
  end
end

Version data entries

120 entries across 120 versions & 32 rubygems

Version Path
noctivityinc-activemerchant-1.5.1 lib/active_merchant/billing/response.rb
activemerchant-1.5.1 lib/active_merchant/billing/response.rb
activemerchant-est-1.4.2.6 lib/active_merchant/billing/response.rb
activemerchant-1.5.0 lib/active_merchant/billing/response.rb
patmaddox-activemerchant-1.4.2.6 lib/active_merchant/billing/response.rb
patmaddox-activemerchant-1.4.2.5 lib/active_merchant/billing/response.rb
patmaddox-activemerchant-1.4.2.4 lib/active_merchant/billing/response.rb
patmaddox-activemerchant-1.4.2.3 lib/active_merchant/billing/response.rb
patmaddox-activemerchant-1.4.2.2 lib/active_merchant/billing/response.rb
patmaddox-activemerchant-1.4.2.1 lib/active_merchant/billing/response.rb
activemerchant-est-1.4.2.5 lib/active_merchant/billing/response.rb
patmaddox-activemerchant-1.4.2 lib/active_merchant/billing/response.rb
abtain_billing-1.0 lib/active_merchant/billing/response.rb
activemerchant-1.3.1 lib/active_merchant/billing/response.rb
activemerchant-1.4.1 lib/active_merchant/billing/response.rb
activemerchant-1.3.2 lib/active_merchant/billing/response.rb
activemerchant-1.4.0 lib/active_merchant/billing/response.rb
activemerchant-1.3.0 lib/active_merchant/billing/response.rb
activemerchant-1.4.2 lib/active_merchant/billing/response.rb
spree-0.2.0 vendor/plugins/active_merchant/lib/active_merchant/billing/response.rb