See Original text in context
method posix(Bool: = False --> Int)
Returns the date and time as a POSIX/UNIX timestamp (integral seconds since the POSIX epoch, 1970-01-01T00:00:00Z).
If $ignore-timezone
is True
, the DateTime
object will be treated as if the time zone offset is zero.
say DateTime.new('2015-12-24T12:23:00Z').posix; # OUTPUT: «1450959780»