struct
Duration::Parser::ISO8601
- Duration::Parser::ISO8601
- Struct
- Value
- Object
Overview
The ISO8601 parser is an incredibly efficient, zero-allocation ISO8601
duration parser. It
parses strings like "P3Y6M4DT12H30M5S" into Duration instances.
# 3 years, 6 months, 4 days, 12 hours, 30 minutes, 5.5 seconds
Duration.parse_iso8601("P3Y6M4DT12H30M5.5S")
# => Duration(@months=42, @days=4, @nanoseconds=45005500000000)