Module: Mutant::Result::Session::Timestamp Private
- Included in:
- Mutant::Result::Session
- Defined in:
- lib/mutant/result/session.rb
Overview
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Extract timestamp from UUIDv7 session_id
Instance Method Summary collapse
- #timestamp ⇒ Time private
Instance Method Details
#timestamp ⇒ Time
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
10 11 12 13 |
# File 'lib/mutant/result/session.rb', line 10 def ms = session_id.delete('-')[0, 12].to_i(16) Time.at(ms / 1000.0).utc end |