javalangString cannot be cast to javalangLong
This error occurs when you try to cast a String object to a Long object, which is not allowed because they are different data types. To fix this error, you need to convert the String to a Long using the Long class's parseLong() method.
Example:
String str = "12345"; Long num = Long.parseLong(str);
AI 优化版
原文地址:https://www.cveoy.top/t/topic/bEw8 著作权归作者所有。请勿转载和采集!