chat_grpc.pb.go 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559
  1. // Code generated by protoc-gen-go-grpc. DO NOT EDIT.
  2. package chat
  3. import (
  4. context "context"
  5. common "git.ikuban.com/server/pw-protobuf/api/common"
  6. grpc "google.golang.org/grpc"
  7. codes "google.golang.org/grpc/codes"
  8. status "google.golang.org/grpc/status"
  9. emptypb "google.golang.org/protobuf/types/known/emptypb"
  10. )
  11. // This is a compile-time assertion to ensure that this generated file
  12. // is compatible with the grpc package it is being compiled against.
  13. // Requires gRPC-Go v1.32.0 or later.
  14. const _ = grpc.SupportPackageIsVersion7
  15. // ChatClient is the client API for Chat service.
  16. //
  17. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
  18. type ChatClient interface {
  19. // 检查用户是否与接待员聊天
  20. CheckUserPartnerIsRelationship(ctx context.Context, in *common.UserAndPartnerIdentifyIdParam, opts ...grpc.CallOption) (*CheckUserPartnerIsRelationshipReply, error)
  21. // 创建聊天房间
  22. CreateChatRoom(ctx context.Context, in *CreateChatRoomParam, opts ...grpc.CallOption) (*RoomReply, error)
  23. // 查询在线人的列表
  24. FindOnlinePersonList(ctx context.Context, in *common.ListPageAndPersonRequest, opts ...grpc.CallOption) (*common.OnlinePersonListReply, error)
  25. // 查询推荐人的列表
  26. FindRecommendPersonList(ctx context.Context, in *common.ListPageAndPersonRequest, opts ...grpc.CallOption) (*common.RecommendPersonListReply, error)
  27. // 接待员查询房间列表
  28. PartnerFindRoomList(ctx context.Context, in *PartnerFindRoomListRequest, opts ...grpc.CallOption) (*PartnerFindRoomListReply, error)
  29. // 用户查询房间列表
  30. UserFindRoomList(ctx context.Context, in *UserFindRoomListRequest, opts ...grpc.CallOption) (*UserFindRoomListReply, error)
  31. Receive(ctx context.Context, in *ReceiveRequest, opts ...grpc.CallOption) (*ReceiveReply, error)
  32. // 查询聊天记录
  33. FindChatRecordList(ctx context.Context, in *FindChatRecordListRequest, opts ...grpc.CallOption) (*common.ChatRecordListReply, error)
  34. // 房间信息
  35. FindChatRoomMsg(ctx context.Context, in *FindChatRoomMsgRequest, opts ...grpc.CallOption) (*common.ChatRoomMsg, error)
  36. // 拉黑
  37. SetBlackChat(ctx context.Context, in *SetBlackChatParam, opts ...grpc.CallOption) (*emptypb.Empty, error)
  38. // 拉黑
  39. Report(ctx context.Context, in *common.ReportRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
  40. // 接待员领取开通奖励
  41. PartnerGetAward(ctx context.Context, in *PartnerGetAwardRequest, opts ...grpc.CallOption) (*PartnerGetAwardReply, error)
  42. // 房间信息
  43. FindRoomCardMsg(ctx context.Context, in *FindRoomCardMsgRequest, opts ...grpc.CallOption) (*common.RoomChatMsg, error)
  44. }
  45. type chatClient struct {
  46. cc grpc.ClientConnInterface
  47. }
  48. func NewChatClient(cc grpc.ClientConnInterface) ChatClient {
  49. return &chatClient{cc}
  50. }
  51. func (c *chatClient) CheckUserPartnerIsRelationship(ctx context.Context, in *common.UserAndPartnerIdentifyIdParam, opts ...grpc.CallOption) (*CheckUserPartnerIsRelationshipReply, error) {
  52. out := new(CheckUserPartnerIsRelationshipReply)
  53. err := c.cc.Invoke(ctx, "/api.chat.Chat/CheckUserPartnerIsRelationship", in, out, opts...)
  54. if err != nil {
  55. return nil, err
  56. }
  57. return out, nil
  58. }
  59. func (c *chatClient) CreateChatRoom(ctx context.Context, in *CreateChatRoomParam, opts ...grpc.CallOption) (*RoomReply, error) {
  60. out := new(RoomReply)
  61. err := c.cc.Invoke(ctx, "/api.chat.Chat/CreateChatRoom", in, out, opts...)
  62. if err != nil {
  63. return nil, err
  64. }
  65. return out, nil
  66. }
  67. func (c *chatClient) FindOnlinePersonList(ctx context.Context, in *common.ListPageAndPersonRequest, opts ...grpc.CallOption) (*common.OnlinePersonListReply, error) {
  68. out := new(common.OnlinePersonListReply)
  69. err := c.cc.Invoke(ctx, "/api.chat.Chat/FindOnlinePersonList", in, out, opts...)
  70. if err != nil {
  71. return nil, err
  72. }
  73. return out, nil
  74. }
  75. func (c *chatClient) FindRecommendPersonList(ctx context.Context, in *common.ListPageAndPersonRequest, opts ...grpc.CallOption) (*common.RecommendPersonListReply, error) {
  76. out := new(common.RecommendPersonListReply)
  77. err := c.cc.Invoke(ctx, "/api.chat.Chat/FindRecommendPersonList", in, out, opts...)
  78. if err != nil {
  79. return nil, err
  80. }
  81. return out, nil
  82. }
  83. func (c *chatClient) PartnerFindRoomList(ctx context.Context, in *PartnerFindRoomListRequest, opts ...grpc.CallOption) (*PartnerFindRoomListReply, error) {
  84. out := new(PartnerFindRoomListReply)
  85. err := c.cc.Invoke(ctx, "/api.chat.Chat/PartnerFindRoomList", in, out, opts...)
  86. if err != nil {
  87. return nil, err
  88. }
  89. return out, nil
  90. }
  91. func (c *chatClient) UserFindRoomList(ctx context.Context, in *UserFindRoomListRequest, opts ...grpc.CallOption) (*UserFindRoomListReply, error) {
  92. out := new(UserFindRoomListReply)
  93. err := c.cc.Invoke(ctx, "/api.chat.Chat/UserFindRoomList", in, out, opts...)
  94. if err != nil {
  95. return nil, err
  96. }
  97. return out, nil
  98. }
  99. func (c *chatClient) Receive(ctx context.Context, in *ReceiveRequest, opts ...grpc.CallOption) (*ReceiveReply, error) {
  100. out := new(ReceiveReply)
  101. err := c.cc.Invoke(ctx, "/api.chat.Chat/Receive", in, out, opts...)
  102. if err != nil {
  103. return nil, err
  104. }
  105. return out, nil
  106. }
  107. func (c *chatClient) FindChatRecordList(ctx context.Context, in *FindChatRecordListRequest, opts ...grpc.CallOption) (*common.ChatRecordListReply, error) {
  108. out := new(common.ChatRecordListReply)
  109. err := c.cc.Invoke(ctx, "/api.chat.Chat/FindChatRecordList", in, out, opts...)
  110. if err != nil {
  111. return nil, err
  112. }
  113. return out, nil
  114. }
  115. func (c *chatClient) FindChatRoomMsg(ctx context.Context, in *FindChatRoomMsgRequest, opts ...grpc.CallOption) (*common.ChatRoomMsg, error) {
  116. out := new(common.ChatRoomMsg)
  117. err := c.cc.Invoke(ctx, "/api.chat.Chat/FindChatRoomMsg", in, out, opts...)
  118. if err != nil {
  119. return nil, err
  120. }
  121. return out, nil
  122. }
  123. func (c *chatClient) SetBlackChat(ctx context.Context, in *SetBlackChatParam, opts ...grpc.CallOption) (*emptypb.Empty, error) {
  124. out := new(emptypb.Empty)
  125. err := c.cc.Invoke(ctx, "/api.chat.Chat/SetBlackChat", in, out, opts...)
  126. if err != nil {
  127. return nil, err
  128. }
  129. return out, nil
  130. }
  131. func (c *chatClient) Report(ctx context.Context, in *common.ReportRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
  132. out := new(emptypb.Empty)
  133. err := c.cc.Invoke(ctx, "/api.chat.Chat/Report", in, out, opts...)
  134. if err != nil {
  135. return nil, err
  136. }
  137. return out, nil
  138. }
  139. func (c *chatClient) PartnerGetAward(ctx context.Context, in *PartnerGetAwardRequest, opts ...grpc.CallOption) (*PartnerGetAwardReply, error) {
  140. out := new(PartnerGetAwardReply)
  141. err := c.cc.Invoke(ctx, "/api.chat.Chat/PartnerGetAward", in, out, opts...)
  142. if err != nil {
  143. return nil, err
  144. }
  145. return out, nil
  146. }
  147. func (c *chatClient) FindRoomCardMsg(ctx context.Context, in *FindRoomCardMsgRequest, opts ...grpc.CallOption) (*common.RoomChatMsg, error) {
  148. out := new(common.RoomChatMsg)
  149. err := c.cc.Invoke(ctx, "/api.chat.Chat/FindRoomCardMsg", in, out, opts...)
  150. if err != nil {
  151. return nil, err
  152. }
  153. return out, nil
  154. }
  155. // ChatServer is the server API for Chat service.
  156. // All implementations must embed UnimplementedChatServer
  157. // for forward compatibility
  158. type ChatServer interface {
  159. // 检查用户是否与接待员聊天
  160. CheckUserPartnerIsRelationship(context.Context, *common.UserAndPartnerIdentifyIdParam) (*CheckUserPartnerIsRelationshipReply, error)
  161. // 创建聊天房间
  162. CreateChatRoom(context.Context, *CreateChatRoomParam) (*RoomReply, error)
  163. // 查询在线人的列表
  164. FindOnlinePersonList(context.Context, *common.ListPageAndPersonRequest) (*common.OnlinePersonListReply, error)
  165. // 查询推荐人的列表
  166. FindRecommendPersonList(context.Context, *common.ListPageAndPersonRequest) (*common.RecommendPersonListReply, error)
  167. // 接待员查询房间列表
  168. PartnerFindRoomList(context.Context, *PartnerFindRoomListRequest) (*PartnerFindRoomListReply, error)
  169. // 用户查询房间列表
  170. UserFindRoomList(context.Context, *UserFindRoomListRequest) (*UserFindRoomListReply, error)
  171. Receive(context.Context, *ReceiveRequest) (*ReceiveReply, error)
  172. // 查询聊天记录
  173. FindChatRecordList(context.Context, *FindChatRecordListRequest) (*common.ChatRecordListReply, error)
  174. // 房间信息
  175. FindChatRoomMsg(context.Context, *FindChatRoomMsgRequest) (*common.ChatRoomMsg, error)
  176. // 拉黑
  177. SetBlackChat(context.Context, *SetBlackChatParam) (*emptypb.Empty, error)
  178. // 拉黑
  179. Report(context.Context, *common.ReportRequest) (*emptypb.Empty, error)
  180. // 接待员领取开通奖励
  181. PartnerGetAward(context.Context, *PartnerGetAwardRequest) (*PartnerGetAwardReply, error)
  182. // 房间信息
  183. FindRoomCardMsg(context.Context, *FindRoomCardMsgRequest) (*common.RoomChatMsg, error)
  184. mustEmbedUnimplementedChatServer()
  185. }
  186. // UnimplementedChatServer must be embedded to have forward compatible implementations.
  187. type UnimplementedChatServer struct {
  188. }
  189. func (UnimplementedChatServer) CheckUserPartnerIsRelationship(context.Context, *common.UserAndPartnerIdentifyIdParam) (*CheckUserPartnerIsRelationshipReply, error) {
  190. return nil, status.Errorf(codes.Unimplemented, "method CheckUserPartnerIsRelationship not implemented")
  191. }
  192. func (UnimplementedChatServer) CreateChatRoom(context.Context, *CreateChatRoomParam) (*RoomReply, error) {
  193. return nil, status.Errorf(codes.Unimplemented, "method CreateChatRoom not implemented")
  194. }
  195. func (UnimplementedChatServer) FindOnlinePersonList(context.Context, *common.ListPageAndPersonRequest) (*common.OnlinePersonListReply, error) {
  196. return nil, status.Errorf(codes.Unimplemented, "method FindOnlinePersonList not implemented")
  197. }
  198. func (UnimplementedChatServer) FindRecommendPersonList(context.Context, *common.ListPageAndPersonRequest) (*common.RecommendPersonListReply, error) {
  199. return nil, status.Errorf(codes.Unimplemented, "method FindRecommendPersonList not implemented")
  200. }
  201. func (UnimplementedChatServer) PartnerFindRoomList(context.Context, *PartnerFindRoomListRequest) (*PartnerFindRoomListReply, error) {
  202. return nil, status.Errorf(codes.Unimplemented, "method PartnerFindRoomList not implemented")
  203. }
  204. func (UnimplementedChatServer) UserFindRoomList(context.Context, *UserFindRoomListRequest) (*UserFindRoomListReply, error) {
  205. return nil, status.Errorf(codes.Unimplemented, "method UserFindRoomList not implemented")
  206. }
  207. func (UnimplementedChatServer) Receive(context.Context, *ReceiveRequest) (*ReceiveReply, error) {
  208. return nil, status.Errorf(codes.Unimplemented, "method Receive not implemented")
  209. }
  210. func (UnimplementedChatServer) FindChatRecordList(context.Context, *FindChatRecordListRequest) (*common.ChatRecordListReply, error) {
  211. return nil, status.Errorf(codes.Unimplemented, "method FindChatRecordList not implemented")
  212. }
  213. func (UnimplementedChatServer) FindChatRoomMsg(context.Context, *FindChatRoomMsgRequest) (*common.ChatRoomMsg, error) {
  214. return nil, status.Errorf(codes.Unimplemented, "method FindChatRoomMsg not implemented")
  215. }
  216. func (UnimplementedChatServer) SetBlackChat(context.Context, *SetBlackChatParam) (*emptypb.Empty, error) {
  217. return nil, status.Errorf(codes.Unimplemented, "method SetBlackChat not implemented")
  218. }
  219. func (UnimplementedChatServer) Report(context.Context, *common.ReportRequest) (*emptypb.Empty, error) {
  220. return nil, status.Errorf(codes.Unimplemented, "method Report not implemented")
  221. }
  222. func (UnimplementedChatServer) PartnerGetAward(context.Context, *PartnerGetAwardRequest) (*PartnerGetAwardReply, error) {
  223. return nil, status.Errorf(codes.Unimplemented, "method PartnerGetAward not implemented")
  224. }
  225. func (UnimplementedChatServer) FindRoomCardMsg(context.Context, *FindRoomCardMsgRequest) (*common.RoomChatMsg, error) {
  226. return nil, status.Errorf(codes.Unimplemented, "method FindRoomCardMsg not implemented")
  227. }
  228. func (UnimplementedChatServer) mustEmbedUnimplementedChatServer() {}
  229. // UnsafeChatServer may be embedded to opt out of forward compatibility for this service.
  230. // Use of this interface is not recommended, as added methods to ChatServer will
  231. // result in compilation errors.
  232. type UnsafeChatServer interface {
  233. mustEmbedUnimplementedChatServer()
  234. }
  235. func RegisterChatServer(s grpc.ServiceRegistrar, srv ChatServer) {
  236. s.RegisterService(&Chat_ServiceDesc, srv)
  237. }
  238. func _Chat_CheckUserPartnerIsRelationship_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  239. in := new(common.UserAndPartnerIdentifyIdParam)
  240. if err := dec(in); err != nil {
  241. return nil, err
  242. }
  243. if interceptor == nil {
  244. return srv.(ChatServer).CheckUserPartnerIsRelationship(ctx, in)
  245. }
  246. info := &grpc.UnaryServerInfo{
  247. Server: srv,
  248. FullMethod: "/api.chat.Chat/CheckUserPartnerIsRelationship",
  249. }
  250. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  251. return srv.(ChatServer).CheckUserPartnerIsRelationship(ctx, req.(*common.UserAndPartnerIdentifyIdParam))
  252. }
  253. return interceptor(ctx, in, info, handler)
  254. }
  255. func _Chat_CreateChatRoom_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  256. in := new(CreateChatRoomParam)
  257. if err := dec(in); err != nil {
  258. return nil, err
  259. }
  260. if interceptor == nil {
  261. return srv.(ChatServer).CreateChatRoom(ctx, in)
  262. }
  263. info := &grpc.UnaryServerInfo{
  264. Server: srv,
  265. FullMethod: "/api.chat.Chat/CreateChatRoom",
  266. }
  267. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  268. return srv.(ChatServer).CreateChatRoom(ctx, req.(*CreateChatRoomParam))
  269. }
  270. return interceptor(ctx, in, info, handler)
  271. }
  272. func _Chat_FindOnlinePersonList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  273. in := new(common.ListPageAndPersonRequest)
  274. if err := dec(in); err != nil {
  275. return nil, err
  276. }
  277. if interceptor == nil {
  278. return srv.(ChatServer).FindOnlinePersonList(ctx, in)
  279. }
  280. info := &grpc.UnaryServerInfo{
  281. Server: srv,
  282. FullMethod: "/api.chat.Chat/FindOnlinePersonList",
  283. }
  284. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  285. return srv.(ChatServer).FindOnlinePersonList(ctx, req.(*common.ListPageAndPersonRequest))
  286. }
  287. return interceptor(ctx, in, info, handler)
  288. }
  289. func _Chat_FindRecommendPersonList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  290. in := new(common.ListPageAndPersonRequest)
  291. if err := dec(in); err != nil {
  292. return nil, err
  293. }
  294. if interceptor == nil {
  295. return srv.(ChatServer).FindRecommendPersonList(ctx, in)
  296. }
  297. info := &grpc.UnaryServerInfo{
  298. Server: srv,
  299. FullMethod: "/api.chat.Chat/FindRecommendPersonList",
  300. }
  301. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  302. return srv.(ChatServer).FindRecommendPersonList(ctx, req.(*common.ListPageAndPersonRequest))
  303. }
  304. return interceptor(ctx, in, info, handler)
  305. }
  306. func _Chat_PartnerFindRoomList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  307. in := new(PartnerFindRoomListRequest)
  308. if err := dec(in); err != nil {
  309. return nil, err
  310. }
  311. if interceptor == nil {
  312. return srv.(ChatServer).PartnerFindRoomList(ctx, in)
  313. }
  314. info := &grpc.UnaryServerInfo{
  315. Server: srv,
  316. FullMethod: "/api.chat.Chat/PartnerFindRoomList",
  317. }
  318. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  319. return srv.(ChatServer).PartnerFindRoomList(ctx, req.(*PartnerFindRoomListRequest))
  320. }
  321. return interceptor(ctx, in, info, handler)
  322. }
  323. func _Chat_UserFindRoomList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  324. in := new(UserFindRoomListRequest)
  325. if err := dec(in); err != nil {
  326. return nil, err
  327. }
  328. if interceptor == nil {
  329. return srv.(ChatServer).UserFindRoomList(ctx, in)
  330. }
  331. info := &grpc.UnaryServerInfo{
  332. Server: srv,
  333. FullMethod: "/api.chat.Chat/UserFindRoomList",
  334. }
  335. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  336. return srv.(ChatServer).UserFindRoomList(ctx, req.(*UserFindRoomListRequest))
  337. }
  338. return interceptor(ctx, in, info, handler)
  339. }
  340. func _Chat_Receive_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  341. in := new(ReceiveRequest)
  342. if err := dec(in); err != nil {
  343. return nil, err
  344. }
  345. if interceptor == nil {
  346. return srv.(ChatServer).Receive(ctx, in)
  347. }
  348. info := &grpc.UnaryServerInfo{
  349. Server: srv,
  350. FullMethod: "/api.chat.Chat/Receive",
  351. }
  352. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  353. return srv.(ChatServer).Receive(ctx, req.(*ReceiveRequest))
  354. }
  355. return interceptor(ctx, in, info, handler)
  356. }
  357. func _Chat_FindChatRecordList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  358. in := new(FindChatRecordListRequest)
  359. if err := dec(in); err != nil {
  360. return nil, err
  361. }
  362. if interceptor == nil {
  363. return srv.(ChatServer).FindChatRecordList(ctx, in)
  364. }
  365. info := &grpc.UnaryServerInfo{
  366. Server: srv,
  367. FullMethod: "/api.chat.Chat/FindChatRecordList",
  368. }
  369. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  370. return srv.(ChatServer).FindChatRecordList(ctx, req.(*FindChatRecordListRequest))
  371. }
  372. return interceptor(ctx, in, info, handler)
  373. }
  374. func _Chat_FindChatRoomMsg_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  375. in := new(FindChatRoomMsgRequest)
  376. if err := dec(in); err != nil {
  377. return nil, err
  378. }
  379. if interceptor == nil {
  380. return srv.(ChatServer).FindChatRoomMsg(ctx, in)
  381. }
  382. info := &grpc.UnaryServerInfo{
  383. Server: srv,
  384. FullMethod: "/api.chat.Chat/FindChatRoomMsg",
  385. }
  386. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  387. return srv.(ChatServer).FindChatRoomMsg(ctx, req.(*FindChatRoomMsgRequest))
  388. }
  389. return interceptor(ctx, in, info, handler)
  390. }
  391. func _Chat_SetBlackChat_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  392. in := new(SetBlackChatParam)
  393. if err := dec(in); err != nil {
  394. return nil, err
  395. }
  396. if interceptor == nil {
  397. return srv.(ChatServer).SetBlackChat(ctx, in)
  398. }
  399. info := &grpc.UnaryServerInfo{
  400. Server: srv,
  401. FullMethod: "/api.chat.Chat/SetBlackChat",
  402. }
  403. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  404. return srv.(ChatServer).SetBlackChat(ctx, req.(*SetBlackChatParam))
  405. }
  406. return interceptor(ctx, in, info, handler)
  407. }
  408. func _Chat_Report_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  409. in := new(common.ReportRequest)
  410. if err := dec(in); err != nil {
  411. return nil, err
  412. }
  413. if interceptor == nil {
  414. return srv.(ChatServer).Report(ctx, in)
  415. }
  416. info := &grpc.UnaryServerInfo{
  417. Server: srv,
  418. FullMethod: "/api.chat.Chat/Report",
  419. }
  420. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  421. return srv.(ChatServer).Report(ctx, req.(*common.ReportRequest))
  422. }
  423. return interceptor(ctx, in, info, handler)
  424. }
  425. func _Chat_PartnerGetAward_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  426. in := new(PartnerGetAwardRequest)
  427. if err := dec(in); err != nil {
  428. return nil, err
  429. }
  430. if interceptor == nil {
  431. return srv.(ChatServer).PartnerGetAward(ctx, in)
  432. }
  433. info := &grpc.UnaryServerInfo{
  434. Server: srv,
  435. FullMethod: "/api.chat.Chat/PartnerGetAward",
  436. }
  437. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  438. return srv.(ChatServer).PartnerGetAward(ctx, req.(*PartnerGetAwardRequest))
  439. }
  440. return interceptor(ctx, in, info, handler)
  441. }
  442. func _Chat_FindRoomCardMsg_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  443. in := new(FindRoomCardMsgRequest)
  444. if err := dec(in); err != nil {
  445. return nil, err
  446. }
  447. if interceptor == nil {
  448. return srv.(ChatServer).FindRoomCardMsg(ctx, in)
  449. }
  450. info := &grpc.UnaryServerInfo{
  451. Server: srv,
  452. FullMethod: "/api.chat.Chat/FindRoomCardMsg",
  453. }
  454. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  455. return srv.(ChatServer).FindRoomCardMsg(ctx, req.(*FindRoomCardMsgRequest))
  456. }
  457. return interceptor(ctx, in, info, handler)
  458. }
  459. // Chat_ServiceDesc is the grpc.ServiceDesc for Chat service.
  460. // It's only intended for direct use with grpc.RegisterService,
  461. // and not to be introspected or modified (even as a copy)
  462. var Chat_ServiceDesc = grpc.ServiceDesc{
  463. ServiceName: "api.chat.Chat",
  464. HandlerType: (*ChatServer)(nil),
  465. Methods: []grpc.MethodDesc{
  466. {
  467. MethodName: "CheckUserPartnerIsRelationship",
  468. Handler: _Chat_CheckUserPartnerIsRelationship_Handler,
  469. },
  470. {
  471. MethodName: "CreateChatRoom",
  472. Handler: _Chat_CreateChatRoom_Handler,
  473. },
  474. {
  475. MethodName: "FindOnlinePersonList",
  476. Handler: _Chat_FindOnlinePersonList_Handler,
  477. },
  478. {
  479. MethodName: "FindRecommendPersonList",
  480. Handler: _Chat_FindRecommendPersonList_Handler,
  481. },
  482. {
  483. MethodName: "PartnerFindRoomList",
  484. Handler: _Chat_PartnerFindRoomList_Handler,
  485. },
  486. {
  487. MethodName: "UserFindRoomList",
  488. Handler: _Chat_UserFindRoomList_Handler,
  489. },
  490. {
  491. MethodName: "Receive",
  492. Handler: _Chat_Receive_Handler,
  493. },
  494. {
  495. MethodName: "FindChatRecordList",
  496. Handler: _Chat_FindChatRecordList_Handler,
  497. },
  498. {
  499. MethodName: "FindChatRoomMsg",
  500. Handler: _Chat_FindChatRoomMsg_Handler,
  501. },
  502. {
  503. MethodName: "SetBlackChat",
  504. Handler: _Chat_SetBlackChat_Handler,
  505. },
  506. {
  507. MethodName: "Report",
  508. Handler: _Chat_Report_Handler,
  509. },
  510. {
  511. MethodName: "PartnerGetAward",
  512. Handler: _Chat_PartnerGetAward_Handler,
  513. },
  514. {
  515. MethodName: "FindRoomCardMsg",
  516. Handler: _Chat_FindRoomCardMsg_Handler,
  517. },
  518. },
  519. Streams: []grpc.StreamDesc{},
  520. Metadata: "chat.proto",
  521. }