module Rubysermon
	class Cpu < ModTemplate

		def initialize
			@y_axis = "CPU Load"
			@graph_name = "CPU Load In Time"

			@cpu_count = File.readlines("/proc/stat").select { |line|
				line =~ /^cpu[\d]/
			}.length

			@load = 0
		end

		def load_options

		end

		def results
			@load = File.read("/proc/loadavg").split(" ").first.to_s
		end

		def notify?

		end

		def y_axis_name
			@y_axis
		end

		def graph_name
			"#@graph_name (CPUs: #@cpu_count)"
		end
	end
end