Method: SSHData::Encoding#decode_time
- Defined in:
- lib/ssh_data/encoding.rb
#decode_time(raw, offset = 0) ⇒ Object
Read a time from the provided raw data.
raw - A binary String. offset - The offset into raw at which to read (default 0).
Returns an Array including the decoded Time and the Integer number of bytes read.
574 575 576 577 |
# File 'lib/ssh_data/encoding.rb', line 574 def decode_time(raw, offset=0) time_raw, read = decode_uint64(raw, offset) [Time.at(time_raw), read] end |