stringutils

package
v0.0.0-...-a89e01d Latest Latest
Warning

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

Go to latest
Published: Jun 26, 2018 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExistSlice

func ExistSlice(srcSlice []string, elem string) bool

比较是否在切片中存在,区分大小写

func ExistSliceFold

func ExistSliceFold(srcSlice []string, elem string) bool

比较是否在切片中存在,不区分大小写

func Float64IsZero

func Float64IsZero(s float64) bool

func GetAfter

func GetAfter(src string, find string) (string, bool)

func GetBefore

func GetBefore(src string, find string) (string, bool)

func GetGuid

func GetGuid() string

生成Guid字串

func RandomCreateBytes

func RandomCreateBytes(n int, alphabets ...byte) []byte

RandomCreateBytes generate random []byte by specify chars.

func RemoveSliceElement

func RemoveSliceElement(val interface{}, index int) interface{}

删除slice中的元素

func StringToUTF16

func StringToUTF16(s string) []uint16

字符串转换uint16

func Substr

func Substr(s string, start, length int) string

取子串

func SumMd5

func SumMd5(txtInput string) string

func UnicodeDecode

func UnicodeDecode(text string) string

func UnicodeEncode

func UnicodeEncode(str string) (js, html string)

Types

This section is empty.

Jump to

Keyboard shortcuts

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