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.



14179
14180
14181
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14179

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

Instance Attribute Details

#valueObject (readonly)

Returns the value of attribute value.



14177
14178
14179
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14177

def value
  @value
end

Class Method Details

.ALLObject



14199
14200
14201
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14199

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



14184
14185
14186
14187
14188
14189
14190
14191
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14184

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



14211
14212
14213
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14211

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

.failedObject



14215
14216
14217
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14215

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



14194
14195
14196
14197
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14194

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

.pendingObject



14203
14204
14205
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14203

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

.updatingObject



14207
14208
14209
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14207

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

Instance Method Details

#to_hashObject



14219
14220
14221
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14219

def to_hash
  value
end