Here you can find the source of formatDisplay(String displayString)
Parameter | Description |
---|---|
displayString | to display in our format |
public static String formatDisplay(String displayString)
//package com.java2s; /**//from ww w. ja v a2 s. co m * Copyright 5AM Solutions Inc, ESAC, ScenPro & SAIC * * Distributed under the OSI-approved BSD 3-Clause License. * See http://ncip.github.com/caintegrator/LICENSE.txt for details. */ import java.text.DecimalFormat; public class Main { private static final DecimalFormat DECIMAL_FORMAT = new DecimalFormat("0.####################"); /** * * @param displayString to display in our format * @return the double display format string */ public static String formatDisplay(String displayString) { return DECIMAL_FORMAT.format(Double.valueOf(displayString)); } /** * * @param value to display in our format * @return the double display format string */ public static String formatDisplay(Double value) { return DECIMAL_FORMAT.format(value); } }