Skip to main content

Crate parse_datetime

Crate parse_datetime 

Source
Expand description

A Rust crate for parsing human-readable relative time strings and human-readable datetime strings. The function supports the following formats for time:

  • ISO formats
  • timezone offsets, e.g., “UTC-0100”
  • unix timestamps, e.g., “@12”
  • relative time to now, e.g. “+1 hour”

Structs§

DateParts
ExtendedDateTime
A date-time representation that supports years beyond Jiff’s civil range.
TimeParts

Enums§

ParseDateTimeError
ParsedDateTime
Parsed datetime output.

Constants§

GNU_MAX_YEAR
Maximum year accepted by GNU date.

Functions§

parse_datetime
Parses a time string and returns a ParsedDateTime representing the absolute time of the string.
parse_datetime_at_date
Parses a time string at a specific date and returns a ParsedDateTime representing the absolute time of the string.