The CDF_ENCODE_EPOCH16 function encodes a CDF_EPOCH16 value into the standard date and time character string.

Examples


test_string = '04-Dec-2005 20:19:18.176.214.648.000' 
test_epoch = CDF_PARSE_EPOCH16(test_string) 
PRINT, CDF_ENCODE_EPOCH16(test_epoch)

IDL Output

04-Dec-2005 20:19:18.176.214.648.000

Syntax


Result = CDF_ENCODE_EPOCH16(Epoch16 [, EPOCH={0 | 1 | 2 | 3}] )

Return Value


Returns the string representation of the given CDF_EPOCH16 value.

Arguments


Epoch16

The double-precision CDF_EPOCH16 value to be encoded.

Note: The CDF_EPOCH16 value can be obtained by calling CDF_EPOCH16 with the COMPUTE keyword, or by calling CDF_PARSE_EPOCH16.

Keywords


EPOCH

Set this keyword equal to one of the following integer values, specifying the epoch mode to use for output of the epoch date string:

Value

Date Format

0

DD-Mon-YYYY hh:mm:ss.ccc.uuu.nnn.ppp
(This is the default)

1

YYYYMMDD.ttttttttttttttt

2

YYYYMMDDss

3

YYYY-MM-DDThh:mm:ss.ccc.uuu.nnn.pppZ
(The characters T and Z are the CDF_EPOCH16 type 3 place holders)

where:

Date Element

Represents

DD

the day of the month (1-31)

Mon

the abbreviated month name: (Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, or Dec)

MM

the month number (1-12)

YYYY

the year (A.D.)

hh

the hour (0-23)

mm

the minute (0-59)

ss

the second (0-59)

ccc

the millisecond (0-999)

uuu

the microsecond (0-999)

nnn

the nanosecond (0-999)

ppp

the picosecond (0-999)

ttttttttttttttt

the fraction of the day (e.g. 500000000000000 is noon).

Version History


6.3

Introduced

See Also


CDF_EPOCH16, CDF_PARSE_EPOCH16