instance method
inspect
Ruby on Rails edge
Signature
inspect()
Returns a string of the object’s date, time, zone, and offset from UTC.
Time.zone.now.inspect # => "2024-11-13 07:00:10.528054960 UTC +00:00"
Source
# File activesupport/lib/active_support/time_with_zone.rb, line 145
def inspect
"#{time.strftime('%F %H:%M:%S.%9N')} #{zone} #{formatted_offset}"
end
Defined in activesupport/lib/active_support/time_with_zone.rb line 145
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveSupport::TimeWithZone