Class: WhiteLabelMachineName::SubscriptionState

Inherits:
Object
  • Object
show all
Defined in:
lib/whitelabelmachinename-ruby-sdk/models/subscription_state.rb

Constant Summary collapse

PENDING =
'PENDING'.freeze
INITIALIZING =
'INITIALIZING'.freeze
FAILED =
'FAILED'.freeze
ACTIVE =
'ACTIVE'.freeze
SUSPENDED =
'SUSPENDED'.freeze
TERMINATION_SCHEDULED =
'TERMINATION_SCHEDULED'.freeze
TERMINATING =
'TERMINATING'.freeze
TERMINATED =
'TERMINATED'.freeze

Instance Method Summary collapse

Instance Method Details

#build_from_hash(value) ⇒ String

Builds the enum from string

Parameters:

  • The (String)

    enum value in the form of the string

Returns:

  • (String)

    The enum value



35
36
37
38
39
# File 'lib/whitelabelmachinename-ruby-sdk/models/subscription_state.rb', line 35

def build_from_hash(value)
  constantValues = SubscriptionState.constants.select { |c| SubscriptionState::const_get(c) == value }
  raise "Invalid ENUM value #{value} for class #SubscriptionState" if constantValues.empty?
  value
end