util

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DecodeGbkStr

func DecodeGbkStr(str string) (string, error)

func DirectoryExists

func DirectoryExists(path string) bool

func Equal

func Equal(a []byte, b []byte) bool

比较两个[]byte是否相同

func FileExists

func FileExists(path string) bool

func FormatPath

func FormatPath(path string) string

func FormatTime

func FormatTime(t time.Time, str string) string

func Max

func Max(x, y int) int

func Min

func Min(x, y int) int

func ReadFile

func ReadFile(path string) []byte

读文件-去除bom

func ReadFileString

func ReadFileString(path string) string

读文件-去除bom

func SearchRune

func SearchRune(text []rune, what string) int

func SearchStr

func SearchStr(text string, what string) int

func SplitRune

func SplitRune(text []rune, what string) [][]rune

func SplitStr

func SplitStr(text string, what string) []string

Types

This section is empty.

Jump to

Keyboard shortcuts

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