Java : convert a String to Int (Unknown Source)

This question already has an answer here:

  • How do I convert a String to an int in Java? 30 answers
  • Integer.parseInt(“9999999990”); [duplicate] 2 answers

  • 98597598684 is greater than Integer.MAX_VALUE . Use

    long id = Long.parseLong(filename1.substring(0, filename1.length() - 4));
    

    你甚至可以尝试new BigInteger("98597598684")

    链接地址: http://www.djcxy.com/p/20926.html

    上一篇: 在Android,JSON中将字符串转换为Int

    下一篇: Java:将字符串转换为Int(未知源)