Sha256: 62ccc5154aaaed252db3465a4bf453a096041915050217d0c3c1e23674dedc2a

Contents?: true

Size: 272 Bytes

Versions: 10

Compression:

Stored size: 272 Bytes

Contents

module Prosperity
  class Helpers::Time 
    def self.beginning_of_hour(date)
      DateTime.new(date.year, date.month, date.day, date.hour)
    end

    def self.end_of_hour(date)
      DateTime.new(date.year, date.month, date.day, date.hour) + 1.hour
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
prosperity-0.0.11 lib/prosperity/helpers/time.rb
prosperity-0.0.10 lib/prosperity/helpers/time.rb
prosperity-0.0.9 lib/prosperity/helpers/time.rb
prosperity-0.0.8 lib/prosperity/helpers/time.rb
prosperity-0.0.7 lib/prosperity/helpers/time.rb
prosperity-0.0.6 lib/prosperity/helpers/time.rb
prosperity-0.0.5 lib/prosperity/helpers/time.rb
prosperity-0.0.4 lib/prosperity/helpers/time.rb
prosperity-0.0.3 lib/prosperity/helpers/time.rb
prosperity-0.0.2 lib/prosperity/helpers/time.rb