class Io::Flow::V0::Models::ReversalErrorCode
Attributes
value[R]
Public Class Methods
ALL()
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 26165 def ReversalErrorCode.ALL @@all ||= [ReversalErrorCode.amount_exceeds_balance, ReversalErrorCode.authorization_declined, ReversalErrorCode.authorization_expired, ReversalErrorCode.invalid_authorization, ReversalErrorCode.invalid_key, ReversalErrorCode.invalid_amount, ReversalErrorCode.invalid_currency, ReversalErrorCode.no_remaining_balance, ReversalErrorCode.partial_reversal_not_supported, ReversalErrorCode.unknown] end
amount_exceeds_balance()
click to toggle source
Amount specified exceeds the remaining authorization balance.
# File lib/flow_commerce/flow_api_v0_client.rb, line 26170 def ReversalErrorCode.amount_exceeds_balance @@_amount_exceeds_balance ||= ReversalErrorCode.new('amount_exceeds_balance') end
apply(value)
click to toggle source
Returns the instance of ReversalErrorCode
for this value, creating a new instance for an unknown value
# File lib/flow_commerce/flow_api_v0_client.rb, line 26150 def ReversalErrorCode.apply(value) if value.instance_of?(ReversalErrorCode) value else HttpClient::Preconditions.assert_class_or_nil('value', value, String) value.nil? ? nil : (from_string(value) || ReversalErrorCode.new(value)) end end
from_string(value)
click to toggle source
Returns the instance of ReversalErrorCode
for this value, or nil if not found
# File lib/flow_commerce/flow_api_v0_client.rb, line 26160 def ReversalErrorCode.from_string(value) HttpClient::Preconditions.assert_class('value', value, String) ReversalErrorCode.ALL.find { |v| v.value == value } end
invalid_amount()
click to toggle source
Amount is not valid - usually because amount was <= 0
# File lib/flow_commerce/flow_api_v0_client.rb, line 26195 def ReversalErrorCode.invalid_amount @@_invalid_amount ||= ReversalErrorCode.new('invalid_amount') end
invalid_currency()
click to toggle source
Currency
is either not known or invalid
# File lib/flow_commerce/flow_api_v0_client.rb, line 26200 def ReversalErrorCode.invalid_currency @@_invalid_currency ||= ReversalErrorCode.new('invalid_currency') end
invalid_key()
click to toggle source
Invalid key
# File lib/flow_commerce/flow_api_v0_client.rb, line 26190 def ReversalErrorCode.invalid_key @@_invalid_key ||= ReversalErrorCode.new('invalid_key') end
new(value)
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 26145 def initialize(value) @value = HttpClient::Preconditions.assert_class('value', value, String) end
no_remaining_balance()
click to toggle source
The authorization has already been fully captured and/or reversed - there are no additional funds to reverse.
# File lib/flow_commerce/flow_api_v0_client.rb, line 26206 def ReversalErrorCode.no_remaining_balance @@_no_remaining_balance ||= ReversalErrorCode.new('no_remaining_balance') end
partial_reversal_not_supported()
click to toggle source
Indicates a request for a partial reversal when the underlying processor does not support it
# File lib/flow_commerce/flow_api_v0_client.rb, line 26212 def ReversalErrorCode.partial_reversal_not_supported @@_partial_reversal_not_supported ||= ReversalErrorCode.new('partial_reversal_not_supported') end
unknown()
click to toggle source
Unknown or other
# File lib/flow_commerce/flow_api_v0_client.rb, line 26217 def ReversalErrorCode.unknown @@_unknown ||= ReversalErrorCode.new('unknown') end
Public Instance Methods
to_hash()
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 26221 def to_hash value end