@Throws(CloneNotSupportedException::class) fun clone(): Any? { val clone: DefaultIntervalXYDataset = super.clone() as DefaultIntervalXYDataset clone.seriesKeys = ArrayList<Any?>(this.seriesKeys) clone.seriesList = ArrayList(this.seriesList.size()) for (i in 0 until this.seriesList.size()) { val data = this.seriesList.get(i) as Array<DoubleArray> val x = data[0] val xStart = data[1] val xEnd = data[2] val y = data[3] val yStart = data[4] val yEnd = data[5] val xx = DoubleArray(x.size) val xxStart = DoubleArray(xStart.size) val xxEnd = DoubleArray(xEnd.size) val yy = DoubleArray(y.size) val yyStart = DoubleArray(yStart.size) val yyEnd = DoubleArray(yEnd.size) System.arraycopy(x, 0, xx, 0, x.size) System.arraycopy(xStart, 0, xxStart, 0, xStart.size) System.arraycopy(xEnd, 0, xxEnd, 0, xEnd.size) System.arraycopy(y, 0, yy, 0, y.size) System.arraycopy(yStart, 0, yyStart, 0, yStart.size) System.arraycopy(yEnd, 0, yyEnd, 0, yEnd.size) clone.seriesList.add(i, arrayOf(xx, xxStart, xxEnd, yy, yyStart, yyEnd)) } return clone }
Returns a clone of this dataset .