Java Long.getLong(String nm)
Syntax
Long.getLong(String nm) has the following syntax.
public static Long getLong(String nm)
Example
In the following code shows how to use Long.getLong(String nm) method.
// w w w . j av a 2 s. c o m
public class Main {
public static void main(String[] args) {
System.setProperty("Java2s.com", "12345");
String str = "Java2s.com";
System.out.println(Long.getLong(str));
}
}
The code above generates the following result.