public int AddSeries(string label, FlotChartSeries lines, int?xaxis = 1, int?yaxis = 1) { FlotChartItem fci = FlotChartItem.CreateNew(label, lines); fci.xaxis = xaxis; fci.yaxis = yaxis; base.Add(fci); return(base.Count - 1); }
public static FlotChartItem CreateNew(string label, FlotChartSeries series) { if (series is FlotChartLine) { return(new FlotChartItemLine(label, series)); } else if (series is FlotChartDashed) { return(new FlotChartItemDashes(label, series)); } else if (series is FlotChartBar) { return(new FlotChartItemBar(label, series)); } else { throw new Exception("unknown flot chart series type : " + series.GetType().ToString()); } }
public FlotChartItemBar(string label, FlotChartSeries series) { this.label = label; this.bars = (FlotChartBar)series; }
public FlotChartItemDashes(string label, FlotChartSeries series) { this.label = label; this.lines = (FlotChartDashed)series; }
public FlotChartItemLine(string label, FlotChartSeries series) { this.label = label; this.lines = (FlotChartLine)series; }