package cpdf

  1. Overview
  2. Docs

C-style strftime

Supports the following format specifiers: %a %A %b %B %s %e %H %I %j %m %M %p %S %T %u %w %Y %%

type t = {
  1. _tm_sec : int;
  2. _tm_min : int;
  3. _tm_hour : int;
  4. _tm_mday : int;
  5. _tm_mon : int;
  6. _tm_year : int;
  7. _tm_wday : int;
  8. _tm_yday : int;
  9. _tm_isdst : bool;
}

Our version of Unix's tm, so Unix not required

val current_time : unit -> t

Get the time now

val dummy : t

A dummy time value

val strftime : ?time:t -> string -> string

Strftime. If time omitted, the current time is used.

OCaml

Innovation. Community. Security.