hash

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2022 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DonateId = iota // DonateId 捐赠信息
	UserId          // UserId 用户信息
)

Variables

View Source
var (
	ErrTypeNotExist = errors.New("type is not exist")
)

Functions

func Decode

func Decode(raw string) ([]int, error)

Decode 对给定数据计算原始数据

func DecodeID

func DecodeID(id string, t int) (uint, error)

DecodeID 计算HashID对应的数据库ID

func Encode

func Encode(v []int) (string, error)

Encode 对给定数据计算HashID

func Id

func Id(id uint, t int) string

Id 计算数据库内主键对应的HashID

Types

This section is empty.

Jump to

Keyboard shortcuts

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