#include <utility/YiTimeConversion.h>
| Enumerator |
|---|
| ZERO_PADDED |
The time will be padded up to 00:00:00 (hh:mm:ss)
|
| UNPADDED |
The time will be minimally expressed. i.e. 1:30:00 instead of 01:30:00
|
| static bool CYITimeConversion::HasHours |
( |
uint64_t |
uTimeSec | ) |
|
|
static |
Returns true if uTimeSec is at least one hour.
| static bool CYITimeConversion::HasMinutes |
( |
uint64_t |
uTimeSec | ) |
|
|
static |
Returns true if uTimeSec is at least one minute.
| static bool CYITimeConversion::HasSeconds |
( |
uint64_t |
uTimeSec | ) |
|
|
static |
Returns true if uTimeSec is at least one second.
| static bool CYITimeConversion::StringToTimeInterval |
( |
const CYIString & |
timeSpan, |
|
|
FORMAT |
eTimeSpanFormat, |
|
|
uint64_t * |
puTimeSec |
|
) |
| |
|
static |
Populates the given uTimeSec with the total seconds expressed by timeSpan (formatted as "hh:mm:ss").
returns false if the timeSpan is malformed, if eTimeSpanFormat is not ZERO_PADDED, or if puTimeSec is null.
| static CYIString CYITimeConversion::TimeIntervalToString |
( |
uint64_t |
uTimeSec, |
|
|
FORMAT |
eTimeSpanFormat |
|
) |
| |
|
static |
- Deprecated:
The provided uTimeSec will be formatted as a time interval string of the form hh:mm:ss. You can specify zero-padding using eTimeSpanFormat.
| static CYIString CYITimeConversion::TimeIntervalToString |
( |
uint64_t |
uTimeSec, |
|
|
const CYIString & |
format |
|
) |
| |
|
static |
Returns a formatted string by taking the provided uTimeSec and a string, format. The format is composed from components, with h%, m%, and s%
as hours, minutes and seconds. Adding more "h", "m", "s" characters to add the numbers that will be zero-padded. "%hhh%:%mm%:%ss%" with a uTimSec of 3601 will return "001:00:01",
and "%m%:%ss%" with a uTimSec of 61 will return "1:01".
The documentation for this class was generated from the following file: