Class: Wallee::RestAddressFormatField

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

Constant Summary collapse

GIVEN_NAME =
'GIVEN_NAME'.freeze
FAMILY_NAME =
'FAMILY_NAME'.freeze
ORGANIZATION_NAME =
'ORGANIZATION_NAME'.freeze
STREET =
'STREET'.freeze
DEPENDENT_LOCALITY =
'DEPENDENT_LOCALITY'.freeze
CITY =
'CITY'.freeze
POSTAL_STATE =
'POSTAL_STATE'.freeze
POST_CODE =
'POST_CODE'.freeze
SORTING_CODE =
'SORTING_CODE'.freeze
COUNTRY =
'COUNTRY'.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



37
38
39
40
41
# File 'lib/wallee-ruby-sdk/models/rest_address_format_field.rb', line 37

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