class Numeric

Public Instance Methods

ago() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 79
def ago
  ::Time.now - self
end
byte()
Alias for: bytes
bytes() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 83
def bytes
  self
end
Also aliased as: byte
day()
Alias for: days
days() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 69
def days
  self * 86_400
end
Also aliased as: day
gigabyte()
Alias for: gigabytes
gigabytes() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 98
def gigabytes
  self * 1024 * 1024 * 1024
end
Also aliased as: gigabyte
hour()
Alias for: hours
hours() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 64
def hours
  self * 3600
end
Also aliased as: hour
kilobyte()
Alias for: kilobytes
kilobytes() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 88
def kilobytes
  self * 1024
end
Also aliased as: kilobyte
megabyte()
Alias for: megabytes
megabytes() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 93
def megabytes
  self * 1024 * 1024
end
Also aliased as: megabyte
minute()
Alias for: minutes
minutes() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 59
def minutes
  self * 60
end
Also aliased as: minute
percent()
Alias for: percents
percents() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 49
def percents
  self
end
Also aliased as: percent
second()
Alias for: seconds
seconds() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 54
def seconds
  self
end
Also aliased as: second
terabyte()
Alias for: terabytes
terabytes() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 103
def terabytes
  self * 1024 * 1024 * 1024 * 1024
end
Also aliased as: terabyte
week()
Alias for: weeks
weeks() click to toggle source
# File lib/eye/utils/mini_active_support.rb, line 74
def weeks
  self * 86_400 * 7
end
Also aliased as: week