Java中String转double有两种方法
参考下面:
String num=“1234”;
double sum1=Double.valueOf(num);
double sum2=Double.parseDouble(num);
如果Map或者HashMap中String转Double报错:
“ Can’t assign java.lang.Double to java.lang.String”
参考下面这篇文章:
https://www.longkui.site/error/cant-assign-java-lang-double-to-java-lang-string/4890/