module Vidibus::Sysinfo

Constants

VERSION

Public Class Methods

cpu() click to toggle source

Returns CPU utilization in percent.

# File lib/vidibus/sysinfo.rb, line 24
def cpu
  Cpu.call
end
load() click to toggle source

Returns system load, divided by number of CPU cores.

# File lib/vidibus/sysinfo.rb, line 29
def load
  Load.call
end
memory() click to toggle source

Returns used memory in megabytes.

# File lib/vidibus/sysinfo.rb, line 51
def memory
  Memory.call
end
storage(mount_point = '/') click to toggle source

Returns consumed storage in gigabytes.

# File lib/vidibus/sysinfo.rb, line 46
def storage(mount_point = '/')
  Storage.call(mount_point)
end
swap() click to toggle source

Returns used swap in megabytes.

# File lib/vidibus/sysinfo.rb, line 56
def swap
  Swap.call
end
system() click to toggle source

Returns system information like CPUs and cores.

# File lib/vidibus/sysinfo.rb, line 19
def system
  System.call
end
throughput(seconds = 1) click to toggle source

Returns currently used throughput in MBit/s. Provide seconds to improve measurement. The higher the seconds, the more accurate are the results.

# File lib/vidibus/sysinfo.rb, line 41
def throughput(seconds = 1)
  Throughput.call(seconds)
end
traffic() click to toggle source

Returns total traffic of this month in gigabytes.

# File lib/vidibus/sysinfo.rb, line 34
def traffic
  Traffic.call
end