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.



15094
15095
15096
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15094

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

Instance Attribute Details

#valueObject (readonly)

Returns the value of attribute value.



15092
15093
15094
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15092

def value
  @value
end

Class Method Details

.ALLObject



15114
15115
15116
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15114

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



15099
15100
15101
15102
15103
15104
15105
15106
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15099

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



15126
15127
15128
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15126

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

.failedObject



15130
15131
15132
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15130

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



15109
15110
15111
15112
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15109

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

.pendingObject



15118
15119
15120
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15118

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

.updatingObject



15122
15123
15124
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15122

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

Instance Method Details

#to_hashObject



15134
15135
15136
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 15134

def to_hash
  value
end