Module: Dynomite::Types

Constant Summary collapse

TYPE_MAP =
{
  string: 'S',
  number: 'N',
  binary: 'B',
  boolean: 'BOOL',
  null: 'NULL',
  map: 'M',
  list: 'L',
  string_set: 'SS',
  number_set: 'NS',
  binary_set: 'BS',
}

Instance Method Summary collapse

Instance Method Details

#type_map(attribute_type) ⇒ Object



18
19
20
# File 'lib/dynomite/types.rb', line 18

def type_map(attribute_type)
  TYPE_MAP[attribute_type.to_s.downcase.to_sym] || attribute_type
end