ApiRPC

package
v0.0.0-...-bbbc4ea Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2019 License: GPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CtxCanceledErr = errors.New("the client canceled or connection time out")

Functions

func AcceptOneNewFriend

func AcceptOneNewFriend(selfId, friendId int64, friendNote string, isAccept bool) error

func AddOneNewFriend

func AddOneNewFriend(selfId, friendId int64, friendNote string) error

func DeleteOneFriend

func DeleteOneFriend(selfId, friendId int64) error

func GetGroupChatsInfoTheUserJoined

func GetGroupChatsInfoTheUserJoined(userId int64) (*mysqlPb.GroupChatInfoListOfUserPlus, error)

func GetMongoDataClient

func GetMongoDataClient() mongoPb.MongoBindServiceClient

Return the client for mongo data rpc server.

func GetMsgNodesDataClient

func GetMsgNodesDataClient() messageNodesPb.NodesDataClient

Return the client for nodes data rpc server.

func GetMySQLDataClient

func GetMySQLDataClient() mysqlPb.MySQLBindServiceClient

Return the client for mysql data rpc server. The type of client is pointer.

func GetOneGroupChatByNameAndManger

func GetOneGroupChatByNameAndManger(name string, managerId int64) (*mysqlPb.GroupChatBasic, error)

func GetOneUserGroupChat

func GetOneUserGroupChat(userId, groupId int64) (*mysqlPb.UserGroupChatRelate, error)

func GetUserByEmail

func GetUserByEmail(email string) (*mysqlPb.UserBasic, error)

func GetUserById

func GetUserById(id int64) (*mysqlPb.UserBasic, error)

func GetUserFriendsInfo

func GetUserFriendsInfo(id int64) (*mysqlPb.FriendsInfoListPlus, error)

func GetUserPasswordById

func GetUserPasswordById(id int64) (*mysqlPb.Password, error)

func GetUsersByName

func GetUsersByName(name string) (*mysqlPb.UserBasicList, error)

func GetUsersInfoOfTheGroupChat

func GetUsersInfoOfTheGroupChat(groupId int64) (*mysqlPb.UserInfoInGroupChatListPlus, error)

func MSGUserNodeAddBlacklist

func MSGUserNodeAddBlacklist(selfId, friendId int64)

func MSGUserNodeAddFriend

func MSGUserNodeAddFriend(selfId, friendId int64)

func MSGUserNodeDelFriend

func MSGUserNodeDelFriend(selfId, friendId int64)

func MSGUserNodeMoveFriendIntoBlacklist

func MSGUserNodeMoveFriendIntoBlacklist(selfId, friendId int64)

func MSGUserNodeMoveFriendOutFromBlacklist

func MSGUserNodeMoveFriendOutFromBlacklist(selfId, friendId int64)

func PutOneFriendIsBlack

func PutOneFriendIsBlack(selfId, friendId int64, isBlack bool) error

func PutOneFriendNote

func PutOneFriendNote(selfId, friendId int64, friendNote string) error

func PutUserAvatarById

func PutUserAvatarById(avatar string, id int64) (*mysqlPb.IdAndAvatar, error)

func PutUserPasswordById

func PutUserPasswordById(password string, id int64) error

func PutUserProfileById

func PutUserProfileById(userId int64, name, mobile string, gender int) (*mysqlPb.UserProfilePlus, error)

func SaveOneNewGroupChat

func SaveOneNewGroupChat(name, avatar, qrCode string, managerId int64) (*mysqlPb.GroupChatBasic, error)

func SaveOneNewUser

func SaveOneNewUser(name, email, mobile, password, avatar, qrCode string, gender int) (*mysqlPb.UserBasic, error)

func StartUserAuthRPCServer

func StartUserAuthRPCServer()

start the user auth gRPC server goroutine

Types

type UserAuth

type UserAuth struct {
}

func (*UserAuth) CheckAuthToken

func (obj *UserAuth) CheckAuthToken(ctx context.Context, param *userAuthPb.Token) (*userAuthPb.Id, error)

Jump to

Keyboard shortcuts

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