Examples of addDataPoint()


Examples of com.serotonin.m2m2.vo.hierarchy.PointHierarchy.addDataPoint()

        PointHierarchy ph = dataPointDao.getPointHierarchy(true).copyFoldersOnly();
        User user = Common.getUser();
        List<DataPointVO> points = dataPointDao.getDataPoints(DataPointExtendedNameComparator.instance, false);
        for (DataPointVO point : points) {
            if (Permissions.hasDataPointReadPermission(user, point))
                ph.addDataPoint(point.getPointFolderId(), new DataPointSummary(point));
        }

        ph.parseEmptyFolders();

        WatchList watchList = new WatchListDao().getSelectedWatchList(user.getId());
View Full Code Here

Examples of org.jsflot.xydata.XYDataList.addDataPoint()

    @Ignore
    public void test_that_XYDataCollection_returns_correct_json() throws JSONException {
        XYDataSetCollection xyCollection = new XYDataSetCollection();
        XYDataList xyList = new XYDataList();
        xyList.setLabel("Set1");
        xyList.addDataPoint(new XYDataPoint(1, 1));
        xyList.addDataPoint(new XYDataPoint(2, 2));
        xyList.addDataPoint(new XYDataPoint(3, 3));
        xyList.addDataPoint(new XYDataPoint(5, 5));
        xyCollection.addDataList(xyList);
View Full Code Here

Examples of org.jsflot.xydata.XYDataList.addDataPoint()

    public void test_that_XYDataCollection_returns_correct_json() throws JSONException {
        XYDataSetCollection xyCollection = new XYDataSetCollection();
        XYDataList xyList = new XYDataList();
        xyList.setLabel("Set1");
        xyList.addDataPoint(new XYDataPoint(1, 1));
        xyList.addDataPoint(new XYDataPoint(2, 2));
        xyList.addDataPoint(new XYDataPoint(3, 3));
        xyList.addDataPoint(new XYDataPoint(5, 5));
        xyCollection.addDataList(xyList);

        StringBuilder expected = new StringBuilder();
View Full Code Here

Examples of org.jsflot.xydata.XYDataList.addDataPoint()

        XYDataSetCollection xyCollection = new XYDataSetCollection();
        XYDataList xyList = new XYDataList();
        xyList.setLabel("Set1");
        xyList.addDataPoint(new XYDataPoint(1, 1));
        xyList.addDataPoint(new XYDataPoint(2, 2));
        xyList.addDataPoint(new XYDataPoint(3, 3));
        xyList.addDataPoint(new XYDataPoint(5, 5));
        xyCollection.addDataList(xyList);

        StringBuilder expected = new StringBuilder();
        expected.append("{\"chart\": [ {\"label\": \"Set1\", \"data\": [[1,1], [2,2], [3,3], [5,5]]}],\"instrumentationNode\":\"chartId\"}");
View Full Code Here

Examples of org.jsflot.xydata.XYDataList.addDataPoint()

        XYDataList xyList = new XYDataList();
        xyList.setLabel("Set1");
        xyList.addDataPoint(new XYDataPoint(1, 1));
        xyList.addDataPoint(new XYDataPoint(2, 2));
        xyList.addDataPoint(new XYDataPoint(3, 3));
        xyList.addDataPoint(new XYDataPoint(5, 5));
        xyCollection.addDataList(xyList);

        StringBuilder expected = new StringBuilder();
        expected.append("{\"chart\": [ {\"label\": \"Set1\", \"data\": [[1,1], [2,2], [3,3], [5,5]]}],\"instrumentationNode\":\"chartId\"}");
        String jsonString = BuildJsonObjectsUtil.generateChartData("chartId", "something", xyCollection, 0l);
View Full Code Here

Examples of org.jsflot.xydata.XYDataList.addDataPoint()

                    //Otherwise return the average
                    currentTick.setY(aggregatedValue / numStatsInCurrentTick);
                }
            }

            valueList.addDataPoint(currentTick);
        }

        valueCollection.addDataList(valueList);
        return valueCollection;
    }
View Full Code Here

Examples of org.jsflot.xydata.XYDataList.addDataPoint()

      errorList.setColor("#eeff00");
      if (alertStatus == AlertStatus.CRITICAL) {
        errorList.setColor("#ff0000");
      }
     
      errorList.addDataPoint(startPoint);
      errorList.addDataPoint(endPoint);
     
      errorList.setShowDataPoints(false);
      errorList.setShowLines(true);
      errorList.setFillLines(false);
View Full Code Here

Examples of org.jsflot.xydata.XYDataList.addDataPoint()

      if (alertStatus == AlertStatus.CRITICAL) {
        errorList.setColor("#ff0000");
      }
     
      errorList.addDataPoint(startPoint);
      errorList.addDataPoint(endPoint);
     
      errorList.setShowDataPoints(false);
      errorList.setShowLines(true);
      errorList.setFillLines(false);
    }
View Full Code Here

Examples of org.openhab.binding.homematic.internal.model.HmChannel.addDatapoint()

    FieldUtils.writeField(channel, "device", device, true);
    FieldUtils.writeField(channel, "number", String.valueOf(channelData.get("INDEX")), true);

    Map<String, ?> paramsList = (Map<String, ?>) channelData.get("PARAMSET");
    for (String name : paramsList.keySet()) {
      channel.addDatapoint(parseDatapoint(channel, name, (Map<String, ?>) paramsList.get(name)));
    }

    return channel;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.