On this page
module ActiveRecord::ConnectionAdapters::PostgreSQLAdapter::OID
Public Class Methods
Alias the old
type to the new
type.
# File activerecord/lib/active_record/connection_adapters/postgresql/oid.rb, line 334
def self.alias_type(new, old)
NAMES[new] = NAMES[old]
end
Register an OID type named name
with a typecasting object in type
. name
should correspond to the `typname` column in the `pg_type` table.
# File activerecord/lib/active_record/connection_adapters/postgresql/oid.rb, line 329
def self.register_type(name, type)
NAMES[name] = type
end
Is name
a registered type?
# File activerecord/lib/active_record/connection_adapters/postgresql/oid.rb, line 339
def self.registered_type?(name)
NAMES.key? name
end
© 2004–2016 David Heinemeier Hansson
Licensed under the MIT License.