class Io::Flow::V0::Models::ReturnPolicyState

Attributes

value[R]

Public Class Methods

ALL() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 25971
def ReturnPolicyState.ALL
  @@all ||= [ReturnPolicyState.current, ReturnPolicyState.deleting, ReturnPolicyState.updating]
end
apply(value) click to toggle source

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

# File lib/flow_commerce/flow_api_v0_client.rb, line 25956
def ReturnPolicyState.apply(value)
  if value.instance_of?(ReturnPolicyState)
    value
  else
    HttpClient::Preconditions.assert_class_or_nil('value', value, String)
    value.nil? ? nil : (from_string(value) || ReturnPolicyState.new(value))
  end
end
current() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 25975
def ReturnPolicyState.current
  @@_current ||= ReturnPolicyState.new('current')
end
deleting() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 25979
def ReturnPolicyState.deleting
  @@_deleting ||= ReturnPolicyState.new('deleting')
end
from_string(value) click to toggle source

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

# File lib/flow_commerce/flow_api_v0_client.rb, line 25966
def ReturnPolicyState.from_string(value)
  HttpClient::Preconditions.assert_class('value', value, String)
  ReturnPolicyState.ALL.find { |v| v.value == value }
end
new(value) click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 25951
def initialize(value)
  @value = HttpClient::Preconditions.assert_class('value', value, String)
end
updating() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 25983
def ReturnPolicyState.updating
  @@_updating ||= ReturnPolicyState.new('updating')
end

Public Instance Methods

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