class CBOR_DIAG::App_dt

Using Time#iso8601 creates the following bugs:

Probably should copy over Time#xmlschema and fix that for us.

Public Class Methods

decode(_, s) click to toggle source
# File lib/cbor-diagnostic-app/dt.rb, line 9
def self.decode(_, s)
  t = Time.iso8601(s)
  if t.subsec != 0
    t.to_f
  else
    t.to_i
  end
end