All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.skillw.attsystem.util.Format.kt Maven / Gradle / Ivy

The newest version!
package com.skillw.attsystem.util

import java.text.NumberFormat

object Format {
    @JvmStatic
    val format: NumberFormat by lazy {
        val numberFormat = NumberFormat.getInstance()
        numberFormat.isGroupingUsed = false
        numberFormat
    }


    @JvmStatic
    fun format(number: Number): String {
        return format.format(number)
    }

    fun Number.real(): String {
        return format.format(this)
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy