Sha256: afc769bbbf3eeadb99b7fc7a077a16519037acbdb3a79105e21b400e432bff57

Contents?: true

Size: 390 Bytes

Versions: 1

Compression:

Stored size: 390 Bytes

Contents

class Fixnum
  def secs
    self
  end

  alias_method :seconds, :secs
  alias_method :sec, :secs

  def mins
    self  * 60
  end

  alias_method :minutes, :mins
  alias_method :min, :mins

  def hours
    self  * 60 * 60
  end

  alias_method :hour, :hours

  def days
    hours * 24
  end

  alias_method :day, :days

  def ago
    Time.new - self
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
marjoree-0.0.9 ./lib/marjoree/time.rb