mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2025-07-19 02:36:59 +00:00
Performance pass 6 (Wrapper type may be primitive)
This commit is contained in:
parent
d9d0f426e4
commit
dba07c1832
@ -876,7 +876,7 @@ public class Form
|
||||
*/
|
||||
public static String ofSize(long s, int div)
|
||||
{
|
||||
Double d = (double) s;
|
||||
double d = (double) s;
|
||||
String sub = "Bytes";
|
||||
|
||||
if(d > div - 1)
|
||||
@ -929,7 +929,7 @@ public class Form
|
||||
*/
|
||||
public static String ofSize(long s, int div, int dec)
|
||||
{
|
||||
Double d = (double) s;
|
||||
double d = (double) s;
|
||||
String sub = "Bytes";
|
||||
|
||||
if(d > div - 1)
|
||||
@ -979,7 +979,7 @@ public class Form
|
||||
{
|
||||
s = -s;
|
||||
}
|
||||
Double d = (double) s;
|
||||
double d = (double) s;
|
||||
String sub = "Grams";
|
||||
|
||||
if(d > div - 1)
|
||||
|
@ -1652,7 +1652,7 @@ public class JSONObject
|
||||
*/
|
||||
public static Object stringToValue(String string)
|
||||
{
|
||||
Double d;
|
||||
double d;
|
||||
if(string.equals(""))
|
||||
{
|
||||
return string;
|
||||
@ -1682,8 +1682,8 @@ public class JSONObject
|
||||
{
|
||||
if(string.indexOf('.') > -1 || string.indexOf('e') > -1 || string.indexOf('E') > -1)
|
||||
{
|
||||
d = Double.valueOf(string);
|
||||
if(!d.isInfinite() && !d.isNaN())
|
||||
d = Double.parseDouble(string);
|
||||
if(!Double.isInfinite(d) && !Double.isNaN(d))
|
||||
{
|
||||
return d;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user