Method: OpenapiClient::ProviderRequest#build_from_hash

Defined in:
lib/openapi_client/models/provider_request.rb

#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



68
69
70
71
72
# File 'lib/openapi_client/models/provider_request.rb', line 68

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