class GraphiteResult {

    public Datapoint getDatapoint() throws MissingDatapointException {
        Double value;
        long timestamp;
        for (int i = 0; i < this.datapoints.length; i++) {
            if (datapoints[i][0] == null)
                continue;

            value = Double.parseDouble(datapoints[i][0]);
            timestamp = Long.parseLong(datapoints[i][1]);
            return new Datapoint(value, timestamp);
        }
        throw new MissingDatapointException();
    }

}