Java Decimal From toDecimal(float value)

Here you can find the source of toDecimal(float value)

Description

to Decimal

License

Open Source License

Declaration

public static float toDecimal(float value) 

Method Source Code

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

public class Main {
    public static float toDecimal(float value) {

        if (value < 100)
            return value / 100;

        while (value > 1) {

            value /= 10;//from   w  w w. j  av  a 2s  . c  om
        }
        return value;
    }
}

Related

  1. toDecimal(final String intValue)
  2. toDecimal(int value, byte[] buffer, int offset, int length, int itemLength, boolean packed)
  3. toDecimal(long val, int places)
  4. toDecimal(String coord)
  5. toDecimal(String number)