Class: ActiveMerchant::Billing::OrbitalGateway::CVVResult

Inherits:
CVVResult
  • Object
show all
Defined in:
lib/active_merchant/billing/gateways/orbital.rb

Overview

Unfortunately, Orbital uses their own special codes for CVV responses that are different than the standard codes defined in ActiveMerchant::Billing::CVVResult.

This class encapsulates the response codes shown on page 255 of their spec: download.chasepaymentech.com/docs/orbital/orbital_gateway_xml_specification.pdf

Constant Summary collapse

MESSAGES =
{
  'M' => 'Match',
  'N' => 'No match',
  'P' => 'Not processed',
  'S' => 'Should have been present',
  'U' => 'Unsupported by issuer/Issuer unable to process request',
  'I' => 'Invalid',
  'Y' => 'Invalid',
  ''  => 'Not applicable'
}

Instance Attribute Summary

Attributes inherited from CVVResult

#code, #message

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from CVVResult

#to_hash

Constructor Details

#initialize(code) ⇒ CVVResult

Returns a new instance of CVVResult.



1260
1261
1262
1263
# File 'lib/active_merchant/billing/gateways/orbital.rb', line 1260

def initialize(code)
  @code = code.blank? ? '' : code.upcase
  @message = MESSAGES[@code]
end

Class Method Details

.messagesObject



1256
1257
1258
# File 'lib/active_merchant/billing/gateways/orbital.rb', line 1256

def self.messages
  MESSAGES
end