Historical updating oE to_unix, Revision 1

to_unix

include datetime.e 
namespace datetime 
public function to_unix(datetime dt) 

converts a datetime value to the Unix numeric format (seconds since EPOCH_1970).

Parameters:
  1. dt : a datetime to be queried.
Returns:

An atom, so this will not overflow during the winter 2038-2039.

Example 1:
secs_since_epoch = to_unix(now()) 
-- secs_since_epoch is equal to the current seconds since epoch 
See Also:

from_unix, format

Not Categorized, Please Help

Search



Quick Links

User menu

Not signed in.

Misc Menu