New list user friends & blocklist calls

This commit is contained in:
2024-07-30 18:31:26 +08:00
parent 82305206b0
commit 4cea915abf
15 changed files with 572 additions and 183 deletions

View File

@ -1,6 +1,6 @@
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.2.0
// - protoc-gen-go-grpc v1.4.0
// - protoc v5.27.1
// source: services.proto
@ -15,8 +15,15 @@ import (
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
// Requires gRPC-Go v1.32.0 or later.
const _ = grpc.SupportPackageIsVersion7
// Requires gRPC-Go v1.62.0 or later.
const _ = grpc.SupportPackageIsVersion8
const (
ServiceDirectory_GetService_FullMethodName = "/proto.ServiceDirectory/GetService"
ServiceDirectory_ListService_FullMethodName = "/proto.ServiceDirectory/ListService"
ServiceDirectory_AddService_FullMethodName = "/proto.ServiceDirectory/AddService"
ServiceDirectory_RemoveService_FullMethodName = "/proto.ServiceDirectory/RemoveService"
)
// ServiceDirectoryClient is the client API for ServiceDirectory service.
//
@ -37,8 +44,9 @@ func NewServiceDirectoryClient(cc grpc.ClientConnInterface) ServiceDirectoryClie
}
func (c *serviceDirectoryClient) GetService(ctx context.Context, in *GetServiceRequest, opts ...grpc.CallOption) (*GetServiceResponse, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(GetServiceResponse)
err := c.cc.Invoke(ctx, "/proto.ServiceDirectory/GetService", in, out, opts...)
err := c.cc.Invoke(ctx, ServiceDirectory_GetService_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
@ -46,8 +54,9 @@ func (c *serviceDirectoryClient) GetService(ctx context.Context, in *GetServiceR
}
func (c *serviceDirectoryClient) ListService(ctx context.Context, in *ListServiceRequest, opts ...grpc.CallOption) (*ListServiceResponse, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(ListServiceResponse)
err := c.cc.Invoke(ctx, "/proto.ServiceDirectory/ListService", in, out, opts...)
err := c.cc.Invoke(ctx, ServiceDirectory_ListService_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
@ -55,8 +64,9 @@ func (c *serviceDirectoryClient) ListService(ctx context.Context, in *ListServic
}
func (c *serviceDirectoryClient) AddService(ctx context.Context, in *ServiceInfo, opts ...grpc.CallOption) (*AddServiceResponse, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(AddServiceResponse)
err := c.cc.Invoke(ctx, "/proto.ServiceDirectory/AddService", in, out, opts...)
err := c.cc.Invoke(ctx, ServiceDirectory_AddService_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
@ -64,8 +74,9 @@ func (c *serviceDirectoryClient) AddService(ctx context.Context, in *ServiceInfo
}
func (c *serviceDirectoryClient) RemoveService(ctx context.Context, in *RemoveServiceRequest, opts ...grpc.CallOption) (*RemoveServiceResponse, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(RemoveServiceResponse)
err := c.cc.Invoke(ctx, "/proto.ServiceDirectory/RemoveService", in, out, opts...)
err := c.cc.Invoke(ctx, ServiceDirectory_RemoveService_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
@ -122,7 +133,7 @@ func _ServiceDirectory_GetService_Handler(srv interface{}, ctx context.Context,
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/proto.ServiceDirectory/GetService",
FullMethod: ServiceDirectory_GetService_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ServiceDirectoryServer).GetService(ctx, req.(*GetServiceRequest))
@ -140,7 +151,7 @@ func _ServiceDirectory_ListService_Handler(srv interface{}, ctx context.Context,
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/proto.ServiceDirectory/ListService",
FullMethod: ServiceDirectory_ListService_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ServiceDirectoryServer).ListService(ctx, req.(*ListServiceRequest))
@ -158,7 +169,7 @@ func _ServiceDirectory_AddService_Handler(srv interface{}, ctx context.Context,
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/proto.ServiceDirectory/AddService",
FullMethod: ServiceDirectory_AddService_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ServiceDirectoryServer).AddService(ctx, req.(*ServiceInfo))
@ -176,7 +187,7 @@ func _ServiceDirectory_RemoveService_Handler(srv interface{}, ctx context.Contex
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/proto.ServiceDirectory/RemoveService",
FullMethod: ServiceDirectory_RemoveService_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ServiceDirectoryServer).RemoveService(ctx, req.(*RemoveServiceRequest))