chat

package
v1.8.4 Latest Latest
Warning

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

Go to latest
Published: Jan 9, 2025 License: GPL-3.0 Imports: 35 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildCredentialPhone added in v1.8.3

func BuildCredentialPhone(areaCode, phone string) string

func DbToPbAttribute

func DbToPbAttribute(attribute *table.Attribute) *common.UserPublicInfo

func DbToPbAttributes

func DbToPbAttributes(attributes []*table.Attribute) []*common.UserPublicInfo

func DbToPbUserFullInfo

func DbToPbUserFullInfo(attribute *table.Attribute) *common.UserFullInfo

func DbToPbUserFullInfos

func DbToPbUserFullInfos(attributes []*table.Attribute) []*common.UserFullInfo

func Start

func Start(ctx context.Context, config *Config, client discovery.SvcDiscoveryRegistry, server *grpc.Server) error

func ToDBAttributeUpdate

func ToDBAttributeUpdate(req *chat.UpdateUserInfoReq) (map[string]any, error)

func ToDBCredentialUpdate added in v1.8.3

func ToDBCredentialUpdate(req *chat.UpdateUserInfoReq, allowChange bool) ([]*chatdb.Credential, []*chatdb.Credential, error)

Types

type CallbackBeforeAddFriendReq

type CallbackBeforeAddFriendReq struct {
	CallbackCommand `json:"callbackCommand"`
	FromUserID      string `json:"fromUserID" `
	ToUserID        string `json:"toUserID"`
	ReqMsg          string `json:"reqMsg"`
	OperationID     string `json:"operationID"`
}

type CallbackCommand

type CallbackCommand string

func (CallbackCommand) GetCallbackCommand

func (c CallbackCommand) GetCallbackCommand() string

type Config

type Config struct {
	RpcConfig     config.Chat
	RedisConfig   config.Redis
	MongodbConfig config.Mongo
	Discovery     config.Discovery
	Share         config.Share
}

Jump to

Keyboard shortcuts

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