Java Number Format numberFormat(double value, String format)

Here you can find the source of numberFormat(double value, String format)

Description

number Format

License

Open Source License

Declaration

public static String numberFormat(double value, String format) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.text.DecimalFormat;

public class Main {

    public static String numberFormat(double value, String format) {
        DecimalFormat objDecimalFormat = new DecimalFormat(format);
        return objDecimalFormat.format(value);
    }// w  w w.  j  a  v  a 2s. co  m
}

Related

  1. formatSafetyNumber(String digits)
  2. formatSheetNumber100(final int sheetNumber)
  3. formatSmallerNumber(String prefix, String suffix, long amnt, boolean useDecimals)
  4. formatTo2Digit(int number)
  5. NumberFormat(double str, int max, int min)
  6. numberFormat(int fractionDigits, Locale locale)
  7. numberFormat(int i)
  8. numberFormat(int num)
  9. numberFormat(Number number, String... pattern)