~ubuntu-branches/ubuntu/maverick/rrdtool/maverick

« back to all changes in this revision

Viewing changes to bindings/ruby/test.rb

  • Committer: Bazaar Package Importer
  • Author(s): Clint Byrum
  • Date: 2010-07-22 08:07:01 UTC
  • mfrom: (1.2.8 upstream) (3.1.6 sid)
  • Revision ID: james.westby@ubuntu.com-20100722080701-k46mgdfz6euxwqsm
Tags: 1.4.3-1ubuntu1
* Merge from debian unstable, Remaining changes:
  - debian/control: Don't build against ruby1.9 as we don't want
    it in main.
* require libdbi >= 0.8.3 to prevent aborts when using dbi datasources

Show diffs side-by-side

added added

removed removed

Lines of Context:
56
56
end
57
57
puts
58
58
 
 
59
# xport method test
 
60
puts "xporting data from #{rrd}"
 
61
(fstart,fend,step,col,legend,data)=RRD.xport(
 
62
        "--start", start_time.to_s, 
 
63
        "--end", (start_time + 300 * 300).to_s, 
 
64
        "--step", 10.to_s, 
 
65
        "DEF:A=#{rrd}:a:AVERAGE",
 
66
        "DEF:B=#{rrd}:b:AVERAGE",
 
67
        "XPORT:A:a",
 
68
        "XPORT:B:b")
 
69
puts "Xported #{col} columns(#{legend.join(", ")}) with #{data.length} rows from #{fstart} to #{fend} and step #{step}\n"
 
70
 
59
71
print "This script has created #{name}.png in the current directory\n";
60
72
print "This demonstrates the use of the TIME and % RPN operators\n";