function updateChartData() {
var test: LineChart.Data[] = [];
for (x in [0..10 step 1]) {
insert LineChart.Data { xValue: x yValue: Math.sin(x)*100 - x } into test
}
var a: HashMap = new HashMap();
a.put(0, test);
delete test;
var retest: LineChart.Data[] = a.get(0) as LineChart.Data[];
println("size of retest is: {sizeof retest}");
println(retest);
}
I get the following exception:
Exception in thread "AWT-EventQueue-0" java.lang.ClassCastException: com.sun.javafx.runtime.sequence.ObjectArraySequence cannot be cast to javafx.scene.chart.LineChart$Data
at com.sasken.vas.application.Main.updateChartdata(Main.fx:263)