// Code generated by liverpcgen, DO NOT EDIT. // source: *.proto files under this directory // If you want to change this file, Please see README in go-common/app/tool/liverpc/protoc-gen-liverpc/ package liverpc import ( "go-common/app/service/live/room/api/liverpc/v1" "go-common/app/service/live/room/api/liverpc/v2" "go-common/library/net/rpc/liverpc" ) // Client that represents a liverpc room service api type Client struct { cli *liverpc.Client // V1AppIndex presents the controller in liverpc V1AppIndex v1.AppIndexRPCClient // V1Area presents the controller in liverpc V1Area v1.AreaRPCClient // V1Room presents the controller in liverpc V1Room v1.RoomRPCClient // V1RoomEx presents the controller in liverpc V1RoomEx v1.RoomExRPCClient // V1RoomMng presents the controller in liverpc V1RoomMng v1.RoomMngRPCClient // V1RoomPendant presents the controller in liverpc V1RoomPendant v1.RoomPendantRPCClient // V1RoomRecommend presents the controller in liverpc V1RoomRecommend v1.RoomRecommendRPCClient // V1Skin presents the controller in liverpc V1Skin v1.SkinRPCClient // V2AppIndex presents the controller in liverpc V2AppIndex v2.AppIndexRPCClient // V2Room presents the controller in liverpc V2Room v2.RoomRPCClient } // DiscoveryAppId the discovery id is not the tree name var DiscoveryAppId = "live.room" // New a Client that represents a liverpc live.room service api // conf can be empty, and it will use discovery to find service by default // conf.AppID will be overwrite by a fixed value DiscoveryAppId // therefore is no need to set func New(conf *liverpc.ClientConfig) *Client { if conf == nil { conf = &liverpc.ClientConfig{} } conf.AppID = DiscoveryAppId var realCli = liverpc.NewClient(conf) cli := &Client{cli: realCli} cli.clientInit(realCli) return cli } func (cli *Client) GetRawCli() *liverpc.Client { return cli.cli } func (cli *Client) clientInit(realCli *liverpc.Client) { cli.V1AppIndex = v1.NewAppIndexRPCClient(realCli) cli.V1Area = v1.NewAreaRPCClient(realCli) cli.V1Room = v1.NewRoomRPCClient(realCli) cli.V1RoomEx = v1.NewRoomExRPCClient(realCli) cli.V1RoomMng = v1.NewRoomMngRPCClient(realCli) cli.V1RoomPendant = v1.NewRoomPendantRPCClient(realCli) cli.V1RoomRecommend = v1.NewRoomRecommendRPCClient(realCli) cli.V1Skin = v1.NewSkinRPCClient(realCli) cli.V2AppIndex = v2.NewAppIndexRPCClient(realCli) cli.V2Room = v2.NewRoomRPCClient(realCli) }