Class: Dropbox::Sign::SignatureRequestResponseDataTypeEnum

Inherits:
Object
  • Object
show all
Defined in:
lib/dropbox-sign/models/signature_request_response_data_type_enum.rb

Constant Summary collapse

TEXT =
"text".freeze
CHECKBOX =
"checkbox".freeze
DATE_SIGNED =
"date_signed".freeze
"dropdown".freeze
INITIALS =
"initials".freeze
RADIO =
"radio".freeze
SIGNATURE =
"signature".freeze
TEXT_MERGE =
"text-merge".freeze
CHECKBOX_MERGE =
"checkbox-merge".freeze

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.all_varsObject



31
32
33
# File 'lib/dropbox-sign/models/signature_request_response_data_type_enum.rb', line 31

def self.all_vars
  @all_vars ||= [TEXT, CHECKBOX, DATE_SIGNED, DROPDOWN, INITIALS, RADIO, SIGNATURE, TEXT_MERGE, CHECKBOX_MERGE].freeze
end

.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



38
39
40
# File 'lib/dropbox-sign/models/signature_request_response_data_type_enum.rb', line 38

def self.build_from_hash(value)
  new.build_from_hash(value)
end

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



45
46
47
48
# File 'lib/dropbox-sign/models/signature_request_response_data_type_enum.rb', line 45

def build_from_hash(value)
  return value if SignatureRequestResponseDataTypeEnum.all_vars.include?(value)
  raise "Invalid ENUM value #{value} for class #SignatureRequestResponseDataTypeEnum"
end