CDF_ENCODE_TT2000
The CDF_ENCODE_TT2000 function encodes a single value or an array of CDF_TIME_TT2000 value(s) into the standard date and time character string(s). The default format of the string is ISO 8601 format:
yyyy-mm-ddThh:mm:ss.cccuuunnn
Examples
epoch_string = '2005-12-04T20:19:18.176321123'
epoch = CDF_PARSE_TT2000(epoch_string)
PRINT, CDF_ENCODE_TT2000(epoch)
CDF_TT2000, epoch2, 2005, 12, 4, 20, 19, 18, 176, 321, /compute
PRINT, CDF_ENCODE_TT2000(epoch2, epoch=0)
IDL Output
2005-12-04T20:19:18.176321123
04-Dec-2005 20:19:18.176321123
Syntax
Result = CDF_ENCODE_TT2000(Epoch [, EPOCH={0 | 1 | 2 | 3}] )
Return Value
Returns a string containing the CDF_TIME_TT2000 values.
Arguments
Epoch
A scalar or an array (<=2D) of CDF_TIME_TT2000 values.
Keywords
EPOCH
Set this keyword equal to one of the following values, specifying the epoch mode to use for output of the epoch string:
Value |
Date Format |
0 |
|
1 |
|
2 |
|
3 |
|
where:
Date Element |
Represents |
|
the day of the month (1-31) |
|
the month number (1-12) |
|
the year (A.D.) |
|
the hour (0-23) |
|
the minute (0-59) |
|
the second (0-59) |
|
the millisecond (0-999), microsecond (000-999) and nanosecond (000-999) |
|
the fraction of the day (e.g. 2500000 is 6 am). |
Version History
3.4.0 |
Introduced |