mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-06-08 07:02:44 -04:00
initial commit. gui prototype v 0.1
This commit is contained in:
parent
e028928571
commit
bc09937785
140 changed files with 5398 additions and 2 deletions
24
src/main/java/io/bitsquare/gui/util/Converter.java
Normal file
24
src/main/java/io/bitsquare/gui/util/Converter.java
Normal file
|
@ -0,0 +1,24 @@
|
|||
package io.bitsquare.gui.util;
|
||||
|
||||
import io.bitsquare.settings.Settings;
|
||||
|
||||
import java.text.DecimalFormat;
|
||||
import java.text.ParseException;
|
||||
|
||||
public class Converter
|
||||
{
|
||||
public static double convertToDouble(String input)
|
||||
{
|
||||
try
|
||||
{
|
||||
DecimalFormat decimalFormat = (DecimalFormat) DecimalFormat.getInstance(Settings.getLocale());
|
||||
return decimalFormat.parse(input).doubleValue();
|
||||
} catch (ParseException e)
|
||||
{
|
||||
//e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates.
|
||||
}
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue