services

package
v0.0.0-...-eb3c019 Latest Latest
Warning

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

Go to latest
Published: Feb 2, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Message

type Message struct {
	Username string `json:"username"`
	Msg      string `json:"msg"`
}

Message 定义了聊天消息的结构

type PixelService

type PixelService struct{}

func (*PixelService) ErrorReporting

func (r *PixelService) ErrorReporting(message string, source string, lineno string, colno string, stack string, accessToken string) (err error)

ErrorReporting 错误上报

func (*PixelService) GenerateCanvasImage

func (r *PixelService) GenerateCanvasImage() (err error)

GenerateCanvasImage 生成画布图片

func (*PixelService) GetChatList

func (r *PixelService) GetChatList() (res []Message, err error)

GetChatList 获取聊天列表

func (*PixelService) GetList

func (r *PixelService) GetList() (res map[string]int64, err error)

GetList 获取画布列表

func (*PixelService) RepairContent

func (r *PixelService) RepairContent() (err error)

RepairContent 修复画布内容

func (*PixelService) SaveChat

func (r *PixelService) SaveChat(username string, msg string) error

SaveChat 保存聊天消息

func (*PixelService) SavePixel

func (r *PixelService) SavePixel(x int64, y int64, color int64, uid int64) (requiredLogin bool, err error)

r表示receive(接受者) 更新像素

type UserService

type UserService struct{}

func (*UserService) GetNicknameById

func (r *UserService) GetNicknameById(uid int64) (nickname string, err error)

GetNicknameById 通过uid获取昵称

func (*UserService) GetOnlineUserList

func (r *UserService) GetOnlineUserList() []map[string]string

GetOnlineUserList 获取在线用户列表

Jump to

Keyboard shortcuts

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