class PlotStatistics implements PlotListener {

    @Override
    public void onAfterDraw(Plot source, Canvas canvas) {
        lastLatency = System.currentTimeMillis() - lastStart;
        if(lastLatency < shortestRenderMs) {
            shortestRenderMs = lastLatency;
        }

        if(lastLatency > longestRenderMs) {
            longestRenderMs = lastLatency;
        }
        latencySum += lastLatency;
        latencySamples++;
        annotatePlot(source, canvas);
    }

    public  PlotStatistics(long updateDelayMs, boolean annotatePlotEnabled);

}