websocket_grpc.pb.go 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502
  1. // Code generated by protoc-gen-go-grpc. DO NOT EDIT.
  2. // versions:
  3. // - protoc-gen-go-grpc v1.3.0
  4. // - protoc v4.22.3
  5. // source: websocket.proto
  6. package websocket
  7. import (
  8. context "context"
  9. grpc "google.golang.org/grpc"
  10. codes "google.golang.org/grpc/codes"
  11. status "google.golang.org/grpc/status"
  12. emptypb "google.golang.org/protobuf/types/known/emptypb"
  13. )
  14. // This is a compile-time assertion to ensure that this generated file
  15. // is compatible with the grpc package it is being compiled against.
  16. // Requires gRPC-Go v1.32.0 or later.
  17. const _ = grpc.SupportPackageIsVersion7
  18. const (
  19. Websocket_FindOnlinePerson_FullMethodName = "/api.websocket.Websocket/FindOnlinePerson"
  20. Websocket_FindOnlinePersonAll_FullMethodName = "/api.websocket.Websocket/FindOnlinePersonAll"
  21. Websocket_FindOnlineCanMatchingPerson_FullMethodName = "/api.websocket.Websocket/FindOnlineCanMatchingPerson"
  22. Websocket_SendMsg_FullMethodName = "/api.websocket.Websocket/SendMsg"
  23. Websocket_UpdateWorkingStatus_FullMethodName = "/api.websocket.Websocket/UpdateWorkingStatus"
  24. Websocket_UpdateWeight_FullMethodName = "/api.websocket.Websocket/UpdateWeight"
  25. Websocket_UpdateTodayMatchedNum_FullMethodName = "/api.websocket.Websocket/UpdateTodayMatchedNum"
  26. Websocket_CheckIsOnline_FullMethodName = "/api.websocket.Websocket/CheckIsOnline"
  27. Websocket_CheckIsOnlineByIDs_FullMethodName = "/api.websocket.Websocket/CheckIsOnlineByIDs"
  28. Websocket_FindOnlinePersonNum_FullMethodName = "/api.websocket.Websocket/FindOnlinePersonNum"
  29. Websocket_CronCheckConnectTime_FullMethodName = "/api.websocket.Websocket/CronCheckConnectTime"
  30. )
  31. // WebsocketClient is the client API for Websocket service.
  32. //
  33. // 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.
  34. type WebsocketClient interface {
  35. // 查询在线人数
  36. FindOnlinePerson(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*FindOnlinePersonReply, error)
  37. // 查询在线人数
  38. FindOnlinePersonAll(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*FindOnlinePersonReply, error)
  39. // 查询在线人数
  40. FindOnlineCanMatchingPerson(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*FindOnlineCanMatchingPersonReply, error)
  41. // 发送消息
  42. SendMsg(ctx context.Context, in *SendMsgRequest, opts ...grpc.CallOption) (*SendMsgReply, error)
  43. // 更新工作状态
  44. UpdateWorkingStatus(ctx context.Context, in *UpdateWorkingStatusRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
  45. // 更新权重
  46. UpdateWeight(ctx context.Context, in *UpdateWeightRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
  47. // 更新每日被匹配数
  48. UpdateTodayMatchedNum(ctx context.Context, in *UpdateTodayMatchedNumRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
  49. // 检查是否在线
  50. CheckIsOnline(ctx context.Context, in *CheckIsOnlineRequest, opts ...grpc.CallOption) (*CheckIsOnlineReply, error)
  51. // 检查是否在线
  52. CheckIsOnlineByIDs(ctx context.Context, in *CheckIsOnlineByIDsParam, opts ...grpc.CallOption) (*CheckIsOnlineByIDsParam, error)
  53. // 查询在线多少人
  54. FindOnlinePersonNum(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*OnlinePersonReply, error)
  55. // 定时检查在线超过一小时的用户并将其下线
  56. CronCheckConnectTime(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*emptypb.Empty, error)
  57. }
  58. type websocketClient struct {
  59. cc grpc.ClientConnInterface
  60. }
  61. func NewWebsocketClient(cc grpc.ClientConnInterface) WebsocketClient {
  62. return &websocketClient{cc}
  63. }
  64. func (c *websocketClient) FindOnlinePerson(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*FindOnlinePersonReply, error) {
  65. out := new(FindOnlinePersonReply)
  66. err := c.cc.Invoke(ctx, Websocket_FindOnlinePerson_FullMethodName, in, out, opts...)
  67. if err != nil {
  68. return nil, err
  69. }
  70. return out, nil
  71. }
  72. func (c *websocketClient) FindOnlinePersonAll(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*FindOnlinePersonReply, error) {
  73. out := new(FindOnlinePersonReply)
  74. err := c.cc.Invoke(ctx, Websocket_FindOnlinePersonAll_FullMethodName, in, out, opts...)
  75. if err != nil {
  76. return nil, err
  77. }
  78. return out, nil
  79. }
  80. func (c *websocketClient) FindOnlineCanMatchingPerson(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*FindOnlineCanMatchingPersonReply, error) {
  81. out := new(FindOnlineCanMatchingPersonReply)
  82. err := c.cc.Invoke(ctx, Websocket_FindOnlineCanMatchingPerson_FullMethodName, in, out, opts...)
  83. if err != nil {
  84. return nil, err
  85. }
  86. return out, nil
  87. }
  88. func (c *websocketClient) SendMsg(ctx context.Context, in *SendMsgRequest, opts ...grpc.CallOption) (*SendMsgReply, error) {
  89. out := new(SendMsgReply)
  90. err := c.cc.Invoke(ctx, Websocket_SendMsg_FullMethodName, in, out, opts...)
  91. if err != nil {
  92. return nil, err
  93. }
  94. return out, nil
  95. }
  96. func (c *websocketClient) UpdateWorkingStatus(ctx context.Context, in *UpdateWorkingStatusRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
  97. out := new(emptypb.Empty)
  98. err := c.cc.Invoke(ctx, Websocket_UpdateWorkingStatus_FullMethodName, in, out, opts...)
  99. if err != nil {
  100. return nil, err
  101. }
  102. return out, nil
  103. }
  104. func (c *websocketClient) UpdateWeight(ctx context.Context, in *UpdateWeightRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
  105. out := new(emptypb.Empty)
  106. err := c.cc.Invoke(ctx, Websocket_UpdateWeight_FullMethodName, in, out, opts...)
  107. if err != nil {
  108. return nil, err
  109. }
  110. return out, nil
  111. }
  112. func (c *websocketClient) UpdateTodayMatchedNum(ctx context.Context, in *UpdateTodayMatchedNumRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
  113. out := new(emptypb.Empty)
  114. err := c.cc.Invoke(ctx, Websocket_UpdateTodayMatchedNum_FullMethodName, in, out, opts...)
  115. if err != nil {
  116. return nil, err
  117. }
  118. return out, nil
  119. }
  120. func (c *websocketClient) CheckIsOnline(ctx context.Context, in *CheckIsOnlineRequest, opts ...grpc.CallOption) (*CheckIsOnlineReply, error) {
  121. out := new(CheckIsOnlineReply)
  122. err := c.cc.Invoke(ctx, Websocket_CheckIsOnline_FullMethodName, in, out, opts...)
  123. if err != nil {
  124. return nil, err
  125. }
  126. return out, nil
  127. }
  128. func (c *websocketClient) CheckIsOnlineByIDs(ctx context.Context, in *CheckIsOnlineByIDsParam, opts ...grpc.CallOption) (*CheckIsOnlineByIDsParam, error) {
  129. out := new(CheckIsOnlineByIDsParam)
  130. err := c.cc.Invoke(ctx, Websocket_CheckIsOnlineByIDs_FullMethodName, in, out, opts...)
  131. if err != nil {
  132. return nil, err
  133. }
  134. return out, nil
  135. }
  136. func (c *websocketClient) FindOnlinePersonNum(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*OnlinePersonReply, error) {
  137. out := new(OnlinePersonReply)
  138. err := c.cc.Invoke(ctx, Websocket_FindOnlinePersonNum_FullMethodName, in, out, opts...)
  139. if err != nil {
  140. return nil, err
  141. }
  142. return out, nil
  143. }
  144. func (c *websocketClient) CronCheckConnectTime(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*emptypb.Empty, error) {
  145. out := new(emptypb.Empty)
  146. err := c.cc.Invoke(ctx, Websocket_CronCheckConnectTime_FullMethodName, in, out, opts...)
  147. if err != nil {
  148. return nil, err
  149. }
  150. return out, nil
  151. }
  152. // WebsocketServer is the server API for Websocket service.
  153. // All implementations must embed UnimplementedWebsocketServer
  154. // for forward compatibility
  155. type WebsocketServer interface {
  156. // 查询在线人数
  157. FindOnlinePerson(context.Context, *emptypb.Empty) (*FindOnlinePersonReply, error)
  158. // 查询在线人数
  159. FindOnlinePersonAll(context.Context, *emptypb.Empty) (*FindOnlinePersonReply, error)
  160. // 查询在线人数
  161. FindOnlineCanMatchingPerson(context.Context, *emptypb.Empty) (*FindOnlineCanMatchingPersonReply, error)
  162. // 发送消息
  163. SendMsg(context.Context, *SendMsgRequest) (*SendMsgReply, error)
  164. // 更新工作状态
  165. UpdateWorkingStatus(context.Context, *UpdateWorkingStatusRequest) (*emptypb.Empty, error)
  166. // 更新权重
  167. UpdateWeight(context.Context, *UpdateWeightRequest) (*emptypb.Empty, error)
  168. // 更新每日被匹配数
  169. UpdateTodayMatchedNum(context.Context, *UpdateTodayMatchedNumRequest) (*emptypb.Empty, error)
  170. // 检查是否在线
  171. CheckIsOnline(context.Context, *CheckIsOnlineRequest) (*CheckIsOnlineReply, error)
  172. // 检查是否在线
  173. CheckIsOnlineByIDs(context.Context, *CheckIsOnlineByIDsParam) (*CheckIsOnlineByIDsParam, error)
  174. // 查询在线多少人
  175. FindOnlinePersonNum(context.Context, *emptypb.Empty) (*OnlinePersonReply, error)
  176. // 定时检查在线超过一小时的用户并将其下线
  177. CronCheckConnectTime(context.Context, *emptypb.Empty) (*emptypb.Empty, error)
  178. mustEmbedUnimplementedWebsocketServer()
  179. }
  180. // UnimplementedWebsocketServer must be embedded to have forward compatible implementations.
  181. type UnimplementedWebsocketServer struct {
  182. }
  183. func (UnimplementedWebsocketServer) FindOnlinePerson(context.Context, *emptypb.Empty) (*FindOnlinePersonReply, error) {
  184. return nil, status.Errorf(codes.Unimplemented, "method FindOnlinePerson not implemented")
  185. }
  186. func (UnimplementedWebsocketServer) FindOnlinePersonAll(context.Context, *emptypb.Empty) (*FindOnlinePersonReply, error) {
  187. return nil, status.Errorf(codes.Unimplemented, "method FindOnlinePersonAll not implemented")
  188. }
  189. func (UnimplementedWebsocketServer) FindOnlineCanMatchingPerson(context.Context, *emptypb.Empty) (*FindOnlineCanMatchingPersonReply, error) {
  190. return nil, status.Errorf(codes.Unimplemented, "method FindOnlineCanMatchingPerson not implemented")
  191. }
  192. func (UnimplementedWebsocketServer) SendMsg(context.Context, *SendMsgRequest) (*SendMsgReply, error) {
  193. return nil, status.Errorf(codes.Unimplemented, "method SendMsg not implemented")
  194. }
  195. func (UnimplementedWebsocketServer) UpdateWorkingStatus(context.Context, *UpdateWorkingStatusRequest) (*emptypb.Empty, error) {
  196. return nil, status.Errorf(codes.Unimplemented, "method UpdateWorkingStatus not implemented")
  197. }
  198. func (UnimplementedWebsocketServer) UpdateWeight(context.Context, *UpdateWeightRequest) (*emptypb.Empty, error) {
  199. return nil, status.Errorf(codes.Unimplemented, "method UpdateWeight not implemented")
  200. }
  201. func (UnimplementedWebsocketServer) UpdateTodayMatchedNum(context.Context, *UpdateTodayMatchedNumRequest) (*emptypb.Empty, error) {
  202. return nil, status.Errorf(codes.Unimplemented, "method UpdateTodayMatchedNum not implemented")
  203. }
  204. func (UnimplementedWebsocketServer) CheckIsOnline(context.Context, *CheckIsOnlineRequest) (*CheckIsOnlineReply, error) {
  205. return nil, status.Errorf(codes.Unimplemented, "method CheckIsOnline not implemented")
  206. }
  207. func (UnimplementedWebsocketServer) CheckIsOnlineByIDs(context.Context, *CheckIsOnlineByIDsParam) (*CheckIsOnlineByIDsParam, error) {
  208. return nil, status.Errorf(codes.Unimplemented, "method CheckIsOnlineByIDs not implemented")
  209. }
  210. func (UnimplementedWebsocketServer) FindOnlinePersonNum(context.Context, *emptypb.Empty) (*OnlinePersonReply, error) {
  211. return nil, status.Errorf(codes.Unimplemented, "method FindOnlinePersonNum not implemented")
  212. }
  213. func (UnimplementedWebsocketServer) CronCheckConnectTime(context.Context, *emptypb.Empty) (*emptypb.Empty, error) {
  214. return nil, status.Errorf(codes.Unimplemented, "method CronCheckConnectTime not implemented")
  215. }
  216. func (UnimplementedWebsocketServer) mustEmbedUnimplementedWebsocketServer() {}
  217. // UnsafeWebsocketServer may be embedded to opt out of forward compatibility for this service.
  218. // Use of this interface is not recommended, as added methods to WebsocketServer will
  219. // result in compilation errors.
  220. type UnsafeWebsocketServer interface {
  221. mustEmbedUnimplementedWebsocketServer()
  222. }
  223. func RegisterWebsocketServer(s grpc.ServiceRegistrar, srv WebsocketServer) {
  224. s.RegisterService(&Websocket_ServiceDesc, srv)
  225. }
  226. func _Websocket_FindOnlinePerson_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  227. in := new(emptypb.Empty)
  228. if err := dec(in); err != nil {
  229. return nil, err
  230. }
  231. if interceptor == nil {
  232. return srv.(WebsocketServer).FindOnlinePerson(ctx, in)
  233. }
  234. info := &grpc.UnaryServerInfo{
  235. Server: srv,
  236. FullMethod: Websocket_FindOnlinePerson_FullMethodName,
  237. }
  238. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  239. return srv.(WebsocketServer).FindOnlinePerson(ctx, req.(*emptypb.Empty))
  240. }
  241. return interceptor(ctx, in, info, handler)
  242. }
  243. func _Websocket_FindOnlinePersonAll_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  244. in := new(emptypb.Empty)
  245. if err := dec(in); err != nil {
  246. return nil, err
  247. }
  248. if interceptor == nil {
  249. return srv.(WebsocketServer).FindOnlinePersonAll(ctx, in)
  250. }
  251. info := &grpc.UnaryServerInfo{
  252. Server: srv,
  253. FullMethod: Websocket_FindOnlinePersonAll_FullMethodName,
  254. }
  255. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  256. return srv.(WebsocketServer).FindOnlinePersonAll(ctx, req.(*emptypb.Empty))
  257. }
  258. return interceptor(ctx, in, info, handler)
  259. }
  260. func _Websocket_FindOnlineCanMatchingPerson_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  261. in := new(emptypb.Empty)
  262. if err := dec(in); err != nil {
  263. return nil, err
  264. }
  265. if interceptor == nil {
  266. return srv.(WebsocketServer).FindOnlineCanMatchingPerson(ctx, in)
  267. }
  268. info := &grpc.UnaryServerInfo{
  269. Server: srv,
  270. FullMethod: Websocket_FindOnlineCanMatchingPerson_FullMethodName,
  271. }
  272. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  273. return srv.(WebsocketServer).FindOnlineCanMatchingPerson(ctx, req.(*emptypb.Empty))
  274. }
  275. return interceptor(ctx, in, info, handler)
  276. }
  277. func _Websocket_SendMsg_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  278. in := new(SendMsgRequest)
  279. if err := dec(in); err != nil {
  280. return nil, err
  281. }
  282. if interceptor == nil {
  283. return srv.(WebsocketServer).SendMsg(ctx, in)
  284. }
  285. info := &grpc.UnaryServerInfo{
  286. Server: srv,
  287. FullMethod: Websocket_SendMsg_FullMethodName,
  288. }
  289. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  290. return srv.(WebsocketServer).SendMsg(ctx, req.(*SendMsgRequest))
  291. }
  292. return interceptor(ctx, in, info, handler)
  293. }
  294. func _Websocket_UpdateWorkingStatus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  295. in := new(UpdateWorkingStatusRequest)
  296. if err := dec(in); err != nil {
  297. return nil, err
  298. }
  299. if interceptor == nil {
  300. return srv.(WebsocketServer).UpdateWorkingStatus(ctx, in)
  301. }
  302. info := &grpc.UnaryServerInfo{
  303. Server: srv,
  304. FullMethod: Websocket_UpdateWorkingStatus_FullMethodName,
  305. }
  306. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  307. return srv.(WebsocketServer).UpdateWorkingStatus(ctx, req.(*UpdateWorkingStatusRequest))
  308. }
  309. return interceptor(ctx, in, info, handler)
  310. }
  311. func _Websocket_UpdateWeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  312. in := new(UpdateWeightRequest)
  313. if err := dec(in); err != nil {
  314. return nil, err
  315. }
  316. if interceptor == nil {
  317. return srv.(WebsocketServer).UpdateWeight(ctx, in)
  318. }
  319. info := &grpc.UnaryServerInfo{
  320. Server: srv,
  321. FullMethod: Websocket_UpdateWeight_FullMethodName,
  322. }
  323. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  324. return srv.(WebsocketServer).UpdateWeight(ctx, req.(*UpdateWeightRequest))
  325. }
  326. return interceptor(ctx, in, info, handler)
  327. }
  328. func _Websocket_UpdateTodayMatchedNum_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  329. in := new(UpdateTodayMatchedNumRequest)
  330. if err := dec(in); err != nil {
  331. return nil, err
  332. }
  333. if interceptor == nil {
  334. return srv.(WebsocketServer).UpdateTodayMatchedNum(ctx, in)
  335. }
  336. info := &grpc.UnaryServerInfo{
  337. Server: srv,
  338. FullMethod: Websocket_UpdateTodayMatchedNum_FullMethodName,
  339. }
  340. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  341. return srv.(WebsocketServer).UpdateTodayMatchedNum(ctx, req.(*UpdateTodayMatchedNumRequest))
  342. }
  343. return interceptor(ctx, in, info, handler)
  344. }
  345. func _Websocket_CheckIsOnline_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  346. in := new(CheckIsOnlineRequest)
  347. if err := dec(in); err != nil {
  348. return nil, err
  349. }
  350. if interceptor == nil {
  351. return srv.(WebsocketServer).CheckIsOnline(ctx, in)
  352. }
  353. info := &grpc.UnaryServerInfo{
  354. Server: srv,
  355. FullMethod: Websocket_CheckIsOnline_FullMethodName,
  356. }
  357. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  358. return srv.(WebsocketServer).CheckIsOnline(ctx, req.(*CheckIsOnlineRequest))
  359. }
  360. return interceptor(ctx, in, info, handler)
  361. }
  362. func _Websocket_CheckIsOnlineByIDs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  363. in := new(CheckIsOnlineByIDsParam)
  364. if err := dec(in); err != nil {
  365. return nil, err
  366. }
  367. if interceptor == nil {
  368. return srv.(WebsocketServer).CheckIsOnlineByIDs(ctx, in)
  369. }
  370. info := &grpc.UnaryServerInfo{
  371. Server: srv,
  372. FullMethod: Websocket_CheckIsOnlineByIDs_FullMethodName,
  373. }
  374. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  375. return srv.(WebsocketServer).CheckIsOnlineByIDs(ctx, req.(*CheckIsOnlineByIDsParam))
  376. }
  377. return interceptor(ctx, in, info, handler)
  378. }
  379. func _Websocket_FindOnlinePersonNum_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  380. in := new(emptypb.Empty)
  381. if err := dec(in); err != nil {
  382. return nil, err
  383. }
  384. if interceptor == nil {
  385. return srv.(WebsocketServer).FindOnlinePersonNum(ctx, in)
  386. }
  387. info := &grpc.UnaryServerInfo{
  388. Server: srv,
  389. FullMethod: Websocket_FindOnlinePersonNum_FullMethodName,
  390. }
  391. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  392. return srv.(WebsocketServer).FindOnlinePersonNum(ctx, req.(*emptypb.Empty))
  393. }
  394. return interceptor(ctx, in, info, handler)
  395. }
  396. func _Websocket_CronCheckConnectTime_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  397. in := new(emptypb.Empty)
  398. if err := dec(in); err != nil {
  399. return nil, err
  400. }
  401. if interceptor == nil {
  402. return srv.(WebsocketServer).CronCheckConnectTime(ctx, in)
  403. }
  404. info := &grpc.UnaryServerInfo{
  405. Server: srv,
  406. FullMethod: Websocket_CronCheckConnectTime_FullMethodName,
  407. }
  408. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  409. return srv.(WebsocketServer).CronCheckConnectTime(ctx, req.(*emptypb.Empty))
  410. }
  411. return interceptor(ctx, in, info, handler)
  412. }
  413. // Websocket_ServiceDesc is the grpc.ServiceDesc for Websocket service.
  414. // It's only intended for direct use with grpc.RegisterService,
  415. // and not to be introspected or modified (even as a copy)
  416. var Websocket_ServiceDesc = grpc.ServiceDesc{
  417. ServiceName: "api.websocket.Websocket",
  418. HandlerType: (*WebsocketServer)(nil),
  419. Methods: []grpc.MethodDesc{
  420. {
  421. MethodName: "FindOnlinePerson",
  422. Handler: _Websocket_FindOnlinePerson_Handler,
  423. },
  424. {
  425. MethodName: "FindOnlinePersonAll",
  426. Handler: _Websocket_FindOnlinePersonAll_Handler,
  427. },
  428. {
  429. MethodName: "FindOnlineCanMatchingPerson",
  430. Handler: _Websocket_FindOnlineCanMatchingPerson_Handler,
  431. },
  432. {
  433. MethodName: "SendMsg",
  434. Handler: _Websocket_SendMsg_Handler,
  435. },
  436. {
  437. MethodName: "UpdateWorkingStatus",
  438. Handler: _Websocket_UpdateWorkingStatus_Handler,
  439. },
  440. {
  441. MethodName: "UpdateWeight",
  442. Handler: _Websocket_UpdateWeight_Handler,
  443. },
  444. {
  445. MethodName: "UpdateTodayMatchedNum",
  446. Handler: _Websocket_UpdateTodayMatchedNum_Handler,
  447. },
  448. {
  449. MethodName: "CheckIsOnline",
  450. Handler: _Websocket_CheckIsOnline_Handler,
  451. },
  452. {
  453. MethodName: "CheckIsOnlineByIDs",
  454. Handler: _Websocket_CheckIsOnlineByIDs_Handler,
  455. },
  456. {
  457. MethodName: "FindOnlinePersonNum",
  458. Handler: _Websocket_FindOnlinePersonNum_Handler,
  459. },
  460. {
  461. MethodName: "CronCheckConnectTime",
  462. Handler: _Websocket_CronCheckConnectTime_Handler,
  463. },
  464. },
  465. Streams: []grpc.StreamDesc{},
  466. Metadata: "websocket.proto",
  467. }