Module Time


module Time: sig  end
Time utility functions to fill in gaps in the Unix library and to be more to my liking.



Getting the time

These are like Unix.BLAH, but storing the time in int32 rather than float.

val time : unit -> int32
val gmtime : int32 -> Unix.tm
val localtime : int32 -> Unix.tm
val mktime : Unix.tm -> int32 * Unix.tm


Pretty-printing a time


val format_tm : string -> Unix.tm -> string
Wrapper for the C strftime() function. See local documentation for it for information on the string argument (strftime()'s format argument)
val format_time : string -> int32 -> string
Same taking a time in seconds
val ctime : int32 -> string
Returns the time as a string with trailing newline

Same taking a Unix.tm

val asctime : Unix.tm -> string
val time_string : int32 -> string
Time as a string without trailing newline

Same taking a Unix.tm

val tm_string : Unix.tm -> string