Module cowboy_clock

Date and time related functions.

Behaviours: gen_server.

Description

Date and time related functions.

While a gen_server process runs in the background to update the cache of formatted dates every second, all API calls are local and directly read from the ETS cache table, providing fast time and date computations.

Function Index

rfc1123/0Return the current date and time formatted according to RFC-1123.
rfc1123/1Return the given date and time formatted according to RFC-1123.
rfc2109/1Return the given date and time formatted according to RFC-2109.

Function Details

rfc1123/0

rfc1123() -> binary()

Return the current date and time formatted according to RFC-1123.

rfc1123/1

rfc1123(DateTime::calendar:datetime()) -> binary()

Return the given date and time formatted according to RFC-1123.

rfc2109/1

rfc2109(X1::calendar:datetime()) -> binary()

Return the given date and time formatted according to RFC-2109.

This format is used in the set-cookie header sent with HTTP responses.


Generated by EDoc, Aug 16 2014, 11:28:17.