Time.truncate

You're seeing just the function truncate, go back to Time module for more information.
Link to this function

truncate(time, precision)

View Source (since 1.6.0)

Specs

truncate(t(), :microsecond | :millisecond | :second) :: t()

Returns the given time with the microsecond field truncated to the given precision (:microsecond, millisecond or :second).

The given time is returned unchanged if it already has lower precision than the given precision.

Examples

iex> Time.truncate(~T[01:01:01.123456], :microsecond)
~T[01:01:01.123456]

iex> Time.truncate(~T[01:01:01.123456], :millisecond)
~T[01:01:01.123]

iex> Time.truncate(~T[01:01:01.123456], :second)
~T[01:01:01]