generator

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: May 13, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	VAL   = 0x3FFFFFFF
	INDEX = 0x0000003D
)

Variables

This section is empty.

Functions

This section is empty.

Types

type CaptchaGenerator

type CaptchaGenerator struct{}

func (CaptchaGenerator) CreateCode

func (cg CaptchaGenerator) CreateCode(captchaType int8) (string, string, string, error)

CreateCode 生成验证码 @Result id 验证码id @Result bse64s 图片base64编码 @Result code 结果 @Result err 错误

func (CaptchaGenerator) VerifyCaptcha

func (cg CaptchaGenerator) VerifyCaptcha(id, value string) bool

VerifyCaptcha 校验验证码 @Pram id 验证码id @Pram value 用户输入的答案 @Result true:正确,false:失败

type ShortUrlGenerator

type ShortUrlGenerator struct {
}

func (ShortUrlGenerator) Transform

func (ShortUrlGenerator) Transform(longURL string) (string, error)

Transform implementation of short url algorithm **/

Jump to

Keyboard shortcuts

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