Method: ActiveRecord::Type::AdapterSpecificRegistry#lookup

Defined in:
activerecord/lib/active_record/type/adapter_specific_registry.rb

#lookup(symbol, *args, **kwargs) ⇒ Object



27
28
29
30
31
32
33
34
35
# File 'activerecord/lib/active_record/type/adapter_specific_registry.rb', line 27

def lookup(symbol, *args, **kwargs)
  registration = find_registration(symbol, *args, **kwargs)

  if registration
    registration.call(self, symbol, *args, **kwargs)
  else
    raise ArgumentError, "Unknown type #{symbol.inspect}"
  end
end