Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DateTime ¶
DateTime parses a date with, optionally a time and a timezone in an RFC3339 style. The accepted formats are:
- 2006-01-02 (interpred as 0 hour, 0 minute and 0 second)
- 2006-01-02Z07:00 (same as the previous one, but with TZ)
- 2006-01-02T15:04:05
- 2006-01-02T15:04:05Z07:00 (time.RFC3339)
- 2006-01-02T15:04:05.999999999Z07:00 (time.RFC3339Nano)
In all dates, the second number indicates the month and the third, the day. Number values less than ten must have a leading zero.
Note that the format Z07:00 indicates that the timezone can be specified as either Z (UTC) or either (+|-)hh:mm.
func Size ¶
Size parses a size with an optional suffix indicating the unit and returns the size in bytes Supported suffixes (case insensitive):
K, KB: kilobytes M, MB: megabytes G, GB: gigabytes T, TB: terabytes
The number before the suffix is parsed as a float, so the size might be specified with decimal places like e.g. 1.5GB.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.