On Aug 30, 3:13 pm, Kirk H. [email protected] wrote:
A voice was heard to utter: “Use the source, Luke! Errr, uh, Trans.
Oh, and the docs!”
The docs would be nice, but ri has been broken for months and I
could not find any mention of the method online.
But you are right I could have checked the source.
p t.round(7).iso8601(10) #=> "2010-03-30T05:43:25.1234568000Z"
p((t + 1.5).round.iso8601(3)) #=> "2000-01-01T00:00:01.000Z"
t = Time.utc(1999,12,31, 23,59,59)
p (t + 0.123456789).round(4).iso8601(6) #=>
Below that is a short, simple to follow implementation. You are
telling it to round to 100000 or 1000000 digits. That’s probably not
what you mean?
I see, so it only rounds sub-seconds per digit. That’s too bad,
Facets’ #round method could round to any second. I have to rename.
load_method': undefined method’ for nil:NilClass