convutils

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 12, 2026 License: MIT Imports: 4 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Closest

func Closest[T constraints.Integer | constraints.Float](v T) string

func ClosestByte

func ClosestByte[T constraints.Integer | constraints.Float](bytes T) string

func ClosestByteWithPrecision

func ClosestByteWithPrecision[T constraints.Integer | constraints.Float](bytes T, precision int) string

func ClosestKWithPrecision

func ClosestKWithPrecision[T constraints.Integer | constraints.Float](v T, precision int) string

func ToFixed

func ToFixed(num float64, precision int) float64

func ToGiga

func ToGiga[T constraints.Integer | constraints.Float](bytes T) float64

func ToGigaByte

func ToGigaByte[T constraints.Integer | constraints.Float](bytes T) float64

func ToKilo

func ToKilo[T constraints.Integer | constraints.Float](bytes T) float64

func ToKiloByte

func ToKiloByte[T constraints.Integer | constraints.Float](bytes T) float64

func ToMega

func ToMega[T constraints.Integer | constraints.Float](bytes T) float64

func ToMegaByte

func ToMegaByte[T constraints.Integer | constraints.Float](bytes T) float64

Types

type Byte

type Byte float64

func (Byte) String

func (r Byte) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL