pvl/rrd/api.py
changeset 232 5894c70dc6a8
parent 155 9f2967ba81ef
equal deleted inserted replaced
231:027a965a630d 232:5894c70dc6a8
    85     if out_file is True :
    85     if out_file is True :
    86         out_file = open(out_path)
    86         out_file = open(out_path)
    87             
    87             
    88     return (width, height), out_lines, out_file
    88     return (width, height), out_lines, out_file
    89 
    89 
       
    90 def report (*defs, **opts) :
       
    91     """
       
    92         Render an output-less graph with only PRINT statements as a textual report.
       
    93 
       
    94         Returns output lines.
       
    95     """
       
    96     
       
    97     # exec
       
    98     width, height, out_lines = cmd(rrdtool.graph, ('/dev/null', ), opts, defs)
       
    99 
       
   100     return out_lines
       
   101 
    90 def fetch (rrd, cf, **opts) :
   102 def fetch (rrd, cf, **opts) :
    91     """
   103     """
    92         Fetch values from RRD.
   104         Fetch values from RRD.
    93 
   105 
    94         Returns
   106         Returns