package syndic

  1. Overview
  2. Docs

Module Syndic.DateSource

Minimal date module required by Syndic.

Sourcetype t = Ptime.t

A date with time.

Sourceval epoch : t

The POSIX time, i.e. Thursday, 1 January 1970 00:00:00 (UTC).

Sourceval compare : t -> t -> int

Compare dates in increasing order.

Sourceval max : t -> t -> t

max d1 d2 return the maximum (i.e. more recent) of the dates d1 and d2.

Sourceval min : t -> t -> t

min d1 d2 return the minimum (i.e. less recent) of the dates d1 and d2.

Sourceval of_rfc822 : string -> t
Sourceval to_rfc822 : t -> string
Sourceval of_rfc3339 : string -> t
Sourceval to_rfc3339 : t -> string
Sourcetype month =
  1. | Jan
  2. | Feb
  3. | Mar
  4. | Apr
  5. | May
  6. | Jun
  7. | Jul
  8. | Aug
  9. | Sep
  10. | Oct
  11. | Nov
  12. | Dec

Month of the year.

Sourceval string_of_month : month -> string

Return the 3 letters identifying the month in English.

Sourceval year : t -> int

Return the 4 digit year of the date.

Sourceval month : t -> month

Return the month of the date.

Sourceval day : t -> int

Return the day of the month (1..31).

Sourceval hour : t -> int
Sourceval minute : t -> int
Sourceval second : t -> float