utils

package
v0.0.0-...-63846e3 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AvailableDiskSize

func AvailableDiskSize() (uint64, error)

AvailableDiskSize 获取磁盘剩余可用空间大小

func CopyDir

func CopyDir(src, dest string, exclude []string) error

CopyDir 拷贝数据目录

func DirSize

func DirSize(dirPath string) (int64, error)

DirSize 获取一个目录的大小

func Float64ToBytes

func Float64ToBytes(float float64) []byte

func FloatFromBytes

func FloatFromBytes(val []byte) float64

func GetTestKey

func GetTestKey(n int) []byte

GetTestKey 生成测试使用的 key

func RandomValue

func RandomValue(n int) []byte

RandomValue 生成随机 value,用于测试

Types

This section is empty.

Jump to

Keyboard shortcuts

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