Method: RRD::Base#fetch
- Defined in:
- lib/rrd/base.rb
#fetch(consolidation_function, options = {}) ⇒ Object
Basic usage: rrd.fetch :average
45 46 47 48 49 50 51 52 53 |
# File 'lib/rrd/base.rb', line 45 def fetch(consolidation_function, = {}) = {:start => Time.now - 1.day, :end => Time.now}.merge [:start] = [:start].to_i [:end] = [:end].to_i line_params = RRD.to_line_parameters() Wrapper.fetch(rrd_file, consolidation_function.to_s.upcase, *line_params) end |