Documentation ¶
Index ¶
- Constants
- func Base2to10[T Number](num T, base T) T
- func Decode(text string, format []string) (string, error)
- func DecodeSlice(text string, format []string, codeSlice CodeSlice) (string, error)
- func DecodeTextByUnicode(text string) (string, error)
- func Encode(text string, format []string) (string, error)
- func EncodeSlice(text string, format []string, codeSlice CodeSlice) (string, error)
- func EncodeTextByUnicode(text string) string
- func N10toBase[T Number](num T, base T) []T
- func Shuffle[T any](arr []T) []T
- func ShuffleStr(str string) string
- type Code
- type CodeSlice
- func (c CodeSlice) FindChar(char string) (*Code, error)
- func (c CodeSlice) FindIndex(index int) (*Code, error)
- func (c CodeSlice) GenHexKey() (*HexKey, error)
- func (c CodeSlice) GenHexKeyFromOrderSlice(orderSlice *CodeSlice) (*HexKey, error)
- func (c CodeSlice) GenInputHexData(text string) (*HexKey, error)
- func (c CodeSlice) GenStr() string
- func (c CodeSlice) ParseHexData(h *HexKey) (string, error)
- func (c CodeSlice) ParseHexDataList(list []string) (string, error)
- type HexKey
- type Number
Constants ¶
View Source
const CodeStr = `abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ,.?!:;+-*/^@0123456789%<>#$&=_|()\"'{}[]~` + "` "
Variables ¶
This section is empty.
Functions ¶
func DecodeSlice ¶
通过自定义字符项数组解码
func EncodeSlice ¶
通过自定义字符项数组编码
Types ¶
type CodeSlice ¶
type CodeSlice []Code
字符项数组
func (CodeSlice) GenHexKeyFromOrderSlice ¶
通过指定的有序的字符项数组 令乱序的字符项数组生成16进制字符串
func (CodeSlice) GenInputHexData ¶
通过 CodeSlice 将指定 string 转为 Hex 码
Click to show internal directories.
Click to hide internal directories.