Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Time

 Time

A talk about how to handle time and timezones. Given at Twente.rb

Dirkjan Bussink

February 10, 2015
Tweet

More Decks by Dirkjan Bussink

Other Decks in Programming

Transcript

  1. UTC

  2. DST

  3. sydney = ActiveSupport::TimeZone[“Australia/Sydney"] ! time => Tue, 19 Aug 2014

    17:15:00 CEST +02:00 time.in_time_zone(sydney) => Wed, 20 Aug 2014 01:15:00 EST +10:00
  4. later = time + 6.months => Thu, 19 Feb 2015

    17:15:00 CET +01:00 ! later.in_time_zone(sydney) => Fri, 20 Feb 2015 03:15:00 EST +11:00
  5. DST

  6. Day!! ! ! ! ! ! ! 2014-10-26! Start!! !

    ! ! ! ! 79200!! ! ! End!! ! ! ! ! ! ! 108000! Duration!! ! 32400