class Io::Flow::V0::Models::RefundStatus

Attributes

value[R]

Public Class Methods

ALL() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 25827
def RefundStatus.ALL
  @@all ||= [RefundStatus.pending, RefundStatus.succeeded, RefundStatus.failed, RefundStatus.canceled]
end
apply(value) click to toggle source

Returns the instance of RefundStatus for this value, creating a new instance for an unknown value

# File lib/flow_commerce/flow_api_v0_client.rb, line 25812
def RefundStatus.apply(value)
  if value.instance_of?(RefundStatus)
    value
  else
    HttpClient::Preconditions.assert_class_or_nil('value', value, String)
    value.nil? ? nil : (from_string(value) || RefundStatus.new(value))
  end
end
canceled() click to toggle source

The refund was canceled.

# File lib/flow_commerce/flow_api_v0_client.rb, line 25847
def RefundStatus.canceled
  @@_canceled ||= RefundStatus.new('canceled')
end
failed() click to toggle source

The refund failed to process.

# File lib/flow_commerce/flow_api_v0_client.rb, line 25842
def RefundStatus.failed
  @@_failed ||= RefundStatus.new('failed')
end
from_string(value) click to toggle source

Returns the instance of RefundStatus for this value, or nil if not found

# File lib/flow_commerce/flow_api_v0_client.rb, line 25822
def RefundStatus.from_string(value)
  HttpClient::Preconditions.assert_class('value', value, String)
  RefundStatus.ALL.find { |v| v.value == value }
end
new(value) click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 25807
def initialize(value)
  @value = HttpClient::Preconditions.assert_class('value', value, String)
end
pending() click to toggle source

The refund has been initiated and requires time to complete.

# File lib/flow_commerce/flow_api_v0_client.rb, line 25832
def RefundStatus.pending
  @@_pending ||= RefundStatus.new('pending')
end
succeeded() click to toggle source

The refund has been processed successfully.

# File lib/flow_commerce/flow_api_v0_client.rb, line 25837
def RefundStatus.succeeded
  @@_succeeded ||= RefundStatus.new('succeeded')
end

Public Instance Methods

to_hash() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 25851
def to_hash
  value
end