X-Git-Url: https://adrianiainlam.tk/git/?a=blobdiff_plain;f=datahandler%2Fbars-custom.js;h=7313ca249201b5cf0b34d24342e6564edc58b54f;hb=a22cc80916b6e165451995e1ae3ed4d36dc86eab;hp=37255e567cad8be36ad6b0797c3115be0e698e1e;hpb=023b7bd44183090c18e450fbd717ad933fac2e41;p=dygraphs.git diff --git a/datahandler/bars-custom.js b/datahandler/bars-custom.js index 37255e5..7313ca2 100644 --- a/datahandler/bars-custom.js +++ b/datahandler/bars-custom.js @@ -14,11 +14,17 @@ /*global Dygraph:false */ "use strict"; -Dygraph.DataHandlers.CustomBarsHandler = Dygraph.DataHandler(); +/** + * @constructor + * @extends Dygraph.DataHandlers.BarsHandler + */ +Dygraph.DataHandlers.CustomBarsHandler = function() { +}; + var CustomBarsHandler = Dygraph.DataHandlers.CustomBarsHandler; CustomBarsHandler.prototype = new Dygraph.DataHandlers.BarsHandler(); -// customBars +/** @inheritDoc */ CustomBarsHandler.prototype.extractSeries = function(rawData, i, options) { // TODO(danvk): pre-allocate series here. var series = []; @@ -49,8 +55,9 @@ CustomBarsHandler.prototype.extractSeries = function(rawData, i, options) { return series; }; -CustomBarsHandler.prototype.rollingAverage = function(originalData, rollPeriod, - options) { +/** @inheritDoc */ +CustomBarsHandler.prototype.rollingAverage = + function(originalData, rollPeriod, options) { rollPeriod = Math.min(rollPeriod, originalData.length); var rollingData = []; var y, low, high, mid,count, i, extremes;