class method
self.fast_string_to_time
Ruby on Rails 2.2.3
Since v2.2.3 Last seen in v3.0.20Signature
self.fast_string_to_time(string)
Doesn’t handle time zones.
Parameters
-
stringreq
Source
# File activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb, line 193
def fast_string_to_time(string)
if string =~ Format::ISO_DATETIME
microsec = ($7.to_f * 1_000_000).to_i
new_time $1.to_i, $2.to_i, $3.to_i, $4.to_i, $5.to_i, $6.to_i, microsec
end
end
Defined in activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb line 193
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::ConnectionAdapters::Column