I\'m trying to create a PieChart in JavaFX, and I want to fill it with data from a HashMap.
PieChart
HashMap
Here\'s my code:
public Graph(HashM
this code snippet:
new PieChart.Data(entry.getKey(), entry.getValue());
entry.getKey() is not string
entry.getKey()
String s = entry.getKey(); new PieChart.Data(s, entry.getValue());
Try it
https://docs.oracle.com/javase/8/javafx/api/javafx/scene/chart/PieChart.Data.html