emozi

package
v1.7.1-0...-0c948e3 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2025 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package emozi 颜文字抽象转写

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type User

type User struct {
	// contains filtered or unexported fields
}

User 用户

func Anonymous

func Anonymous() (usr User)

Anonymous 创建匿名用户

有访问请求数限制

func NewUser

func NewUser(name, pswd string) (usr User)

NewUser 创建已注册用户实例

注册请前往 API 网址

func (*User) IsValid

func (usr *User) IsValid() bool

IsValid 检查是否有效

func (*User) Login

func (usr *User) Login() error

Login 登录

func (*User) Marshal

func (usr *User) Marshal(randomSameMeaning bool, text string, choices ...int) (string, []int, error)

Marshal 编码

  • randomSameMeaning 随机使用近音颜文字
  • text 中文文本
  • choices 多音字选择

func (*User) Unmarshal

func (usr *User) Unmarshal(force bool, text string) (string, error)

Unmarshal 解码

  • force 强制解码不是由程序生成的转写
  • text 颜文字文本

Jump to

Keyboard shortcuts

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