Cldr.DateTime.Formatter.minute
You're seeing just the function
minute, go back to Cldr.DateTime.Formatter module for more information.
Specs
minute(Calendar.time(), integer(), Keyword.t()) :: String.t() | {:error, String.t()}
Returns the :minute of a time or datetime (format symbol m) as number
in string format. The number of m's in the format determines the formatting.
Arguments
timeis aTimestruct or any map that contains at least the key:minutenis the number of digits to which:minuteis paddedlocaleis any valid locale name returned byCldr.known_locale_names/0or aCldr.LanguageTagstruct. The default isCldr.get_locale/0optionsis aKeywordlist of options. There are no options used inminute/4
Format Symbol
The representation of the minute is made in accordance with the following
table:
| Symbol | Results | Description |
|---|---|---|
| m | 3, 10 | Minimim digits of minutes |
| mm | "03", "12" | Number of minutes zero-padded to 2 digits |
Examples
iex> Cldr.DateTime.Formatter.minute %{minute: 3}, 1
3
iex> Cldr.DateTime.Formatter.minute %{minute: 3}, 2
"03"
Specs
minute(Calendar.time(), integer(), locale(), Cldr.backend(), Keyword.t()) :: String.t() | {:error, String.t()}