Package net.sourceforge.jrrd

Examples of net.sourceforge.jrrd.RRDatabase


import net.sourceforge.jrrd.RRDatabase;

public class SimpleFetch1 {

  public SimpleFetch1(String rrdFile) {
    RRDatabase rrd = null;
    DataChunk chunk = null;
    try {
      rrd = new RRDatabase(rrdFile);
      // no period specified, so request the last 24 hours
      chunk = rrd.getData(ConsolidationFunctionType.AVERAGE);
      // retrieve the data for the first datasource
      Map<Date, Double> values = chunk.toMap(0);
            for(Map.Entry<Date, Double> entry : values.entrySet()) {
                Date index = entry.getKey();
                double v = entry.getValue();
View Full Code Here


import net.sourceforge.jrrd.RRDatabase;

public class SimpleFetch2 {

  public SimpleFetch2(String rrdFile) {
    RRDatabase rrd = null;
    DataChunk chunk = null;
    try {
      rrd = new RRDatabase(rrdFile);
      // no period specified, so request the last 24 hours
      chunk = rrd.getData(ConsolidationFunctionType.AVERAGE);
      // retreive the data for the first datasource
      Map<Date, Double> values = chunk.toMap(0);
            for(Map.Entry<Date, Double> entry : values.entrySet()) {
                Date index = entry.getKey();
                double v = entry.getValue();
View Full Code Here

TOP

Related Classes of net.sourceforge.jrrd.RRDatabase

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.