Class: Io::Flow::V0::Models::ExperienceCloneStatus

Inherits:
Object
  • Object
show all
Defined in:
lib/flow_commerce/flow_api_v0_client.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value) ⇒ ExperienceCloneStatus

Returns a new instance of ExperienceCloneStatus.



18020
18021
18022
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18020

def initialize(value)
  @value = HttpClient::Preconditions.assert_class('value', value, String)
end

Instance Attribute Details

#valueObject (readonly)

Returns the value of attribute value.



18018
18019
18020
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18018

def value
  @value
end

Class Method Details

.ALLObject



18040
18041
18042
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18040

def ExperienceCloneStatus.ALL
  @@all ||= [ExperienceCloneStatus.pending, ExperienceCloneStatus.updating, ExperienceCloneStatus.completed, ExperienceCloneStatus.failed]
end

.apply(value) ⇒ Object

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



18025
18026
18027
18028
18029
18030
18031
18032
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18025

def ExperienceCloneStatus.apply(value)
  if value.instance_of?(ExperienceCloneStatus)
    value
  else
    HttpClient::Preconditions.assert_class_or_nil('value', value, String)
    value.nil? ? nil : (from_string(value) || ExperienceCloneStatus.new(value))
  end
end

.completedObject



18052
18053
18054
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18052

def ExperienceCloneStatus.completed
  @@_completed ||= ExperienceCloneStatus.new('completed')
end

.failedObject



18056
18057
18058
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18056

def ExperienceCloneStatus.failed
  @@_failed ||= ExperienceCloneStatus.new('failed')
end

.from_string(value) ⇒ Object

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



18035
18036
18037
18038
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18035

def ExperienceCloneStatus.from_string(value)
  HttpClient::Preconditions.assert_class('value', value, String)
  ExperienceCloneStatus.ALL.find { |v| v.value == value }
end

.pendingObject



18044
18045
18046
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18044

def ExperienceCloneStatus.pending
  @@_pending ||= ExperienceCloneStatus.new('pending')
end

.updatingObject



18048
18049
18050
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18048

def ExperienceCloneStatus.updating
  @@_updating ||= ExperienceCloneStatus.new('updating')
end

Instance Method Details

#to_hashObject



18060
18061
18062
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 18060

def to_hash
  value
end