fun updateDataset(source: CandleDataset?, seriesIndex: Int, newBar: Boolean) { requireNotNull(source) { "Null source (CandleDataset)." } for (i in 0 until this.getSeriesCount()) { val series: CandleSeries = this.getSeries(i) series.updateSeries( source.getSeries(seriesIndex), source.getSeries(seriesIndex).getItemCount() - 1, newBar ) } }
Method updateDataset .