Files
juwan-backend/app/community/rpc/pb/community_grpc.pb.go
T
wwweww 19cc7a778c Refactor: Remove deprecated gRPC service files and implement new API structure
- Deleted old gRPC service definitions in `game_grpc.pb.go` and `public.go`.
- Added new API server implementations for objectstory, player, and shop services.
- Introduced configuration files for new APIs in `etc/*.yaml`.
- Created main entry points for each service in `objectstory.go`, `player.go`, and `shop.go`.
- Removed unused user update handler and user API files.
- Added utility functions for context management and HTTP header parsing.
- Introduced PostgreSQL backup configuration in `backup/postgreSql.yaml`.
2026-02-28 18:35:56 +08:00

852 lines
36 KiB
Go

// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.6.1
// - protoc v5.29.6
// source: community.proto
package pb
import (
context "context"
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
)
// 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.64.0 or later.
const _ = grpc.SupportPackageIsVersion9
const (
CommunityService_AddCommentLikes_FullMethodName = "/pb.communityService/AddCommentLikes"
CommunityService_UpdateCommentLikes_FullMethodName = "/pb.communityService/UpdateCommentLikes"
CommunityService_DelCommentLikes_FullMethodName = "/pb.communityService/DelCommentLikes"
CommunityService_GetCommentLikesById_FullMethodName = "/pb.communityService/GetCommentLikesById"
CommunityService_SearchCommentLikes_FullMethodName = "/pb.communityService/SearchCommentLikes"
CommunityService_AddComments_FullMethodName = "/pb.communityService/AddComments"
CommunityService_UpdateComments_FullMethodName = "/pb.communityService/UpdateComments"
CommunityService_DelComments_FullMethodName = "/pb.communityService/DelComments"
CommunityService_GetCommentsById_FullMethodName = "/pb.communityService/GetCommentsById"
CommunityService_SearchComments_FullMethodName = "/pb.communityService/SearchComments"
CommunityService_AddPostLikes_FullMethodName = "/pb.communityService/AddPostLikes"
CommunityService_UpdatePostLikes_FullMethodName = "/pb.communityService/UpdatePostLikes"
CommunityService_DelPostLikes_FullMethodName = "/pb.communityService/DelPostLikes"
CommunityService_GetPostLikesById_FullMethodName = "/pb.communityService/GetPostLikesById"
CommunityService_SearchPostLikes_FullMethodName = "/pb.communityService/SearchPostLikes"
CommunityService_AddPosts_FullMethodName = "/pb.communityService/AddPosts"
CommunityService_UpdatePosts_FullMethodName = "/pb.communityService/UpdatePosts"
CommunityService_DelPosts_FullMethodName = "/pb.communityService/DelPosts"
CommunityService_GetPostsById_FullMethodName = "/pb.communityService/GetPostsById"
CommunityService_SearchPosts_FullMethodName = "/pb.communityService/SearchPosts"
)
// CommunityServiceClient is the client API for CommunityService service.
//
// 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.
type CommunityServiceClient interface {
// -----------------------commentLikes-----------------------
AddCommentLikes(ctx context.Context, in *AddCommentLikesReq, opts ...grpc.CallOption) (*AddCommentLikesResp, error)
UpdateCommentLikes(ctx context.Context, in *UpdateCommentLikesReq, opts ...grpc.CallOption) (*UpdateCommentLikesResp, error)
DelCommentLikes(ctx context.Context, in *DelCommentLikesReq, opts ...grpc.CallOption) (*DelCommentLikesResp, error)
GetCommentLikesById(ctx context.Context, in *GetCommentLikesByIdReq, opts ...grpc.CallOption) (*GetCommentLikesByIdResp, error)
SearchCommentLikes(ctx context.Context, in *SearchCommentLikesReq, opts ...grpc.CallOption) (*SearchCommentLikesResp, error)
// -----------------------comments-----------------------
AddComments(ctx context.Context, in *AddCommentsReq, opts ...grpc.CallOption) (*AddCommentsResp, error)
UpdateComments(ctx context.Context, in *UpdateCommentsReq, opts ...grpc.CallOption) (*UpdateCommentsResp, error)
DelComments(ctx context.Context, in *DelCommentsReq, opts ...grpc.CallOption) (*DelCommentsResp, error)
GetCommentsById(ctx context.Context, in *GetCommentsByIdReq, opts ...grpc.CallOption) (*GetCommentsByIdResp, error)
SearchComments(ctx context.Context, in *SearchCommentsReq, opts ...grpc.CallOption) (*SearchCommentsResp, error)
// -----------------------postLikes-----------------------
AddPostLikes(ctx context.Context, in *AddPostLikesReq, opts ...grpc.CallOption) (*AddPostLikesResp, error)
UpdatePostLikes(ctx context.Context, in *UpdatePostLikesReq, opts ...grpc.CallOption) (*UpdatePostLikesResp, error)
DelPostLikes(ctx context.Context, in *DelPostLikesReq, opts ...grpc.CallOption) (*DelPostLikesResp, error)
GetPostLikesById(ctx context.Context, in *GetPostLikesByIdReq, opts ...grpc.CallOption) (*GetPostLikesByIdResp, error)
SearchPostLikes(ctx context.Context, in *SearchPostLikesReq, opts ...grpc.CallOption) (*SearchPostLikesResp, error)
// -----------------------posts-----------------------
AddPosts(ctx context.Context, in *AddPostsReq, opts ...grpc.CallOption) (*AddPostsResp, error)
UpdatePosts(ctx context.Context, in *UpdatePostsReq, opts ...grpc.CallOption) (*UpdatePostsResp, error)
DelPosts(ctx context.Context, in *DelPostsReq, opts ...grpc.CallOption) (*DelPostsResp, error)
GetPostsById(ctx context.Context, in *GetPostsByIdReq, opts ...grpc.CallOption) (*GetPostsByIdResp, error)
SearchPosts(ctx context.Context, in *SearchPostsReq, opts ...grpc.CallOption) (*SearchPostsResp, error)
}
type communityServiceClient struct {
cc grpc.ClientConnInterface
}
func NewCommunityServiceClient(cc grpc.ClientConnInterface) CommunityServiceClient {
return &communityServiceClient{cc}
}
func (c *communityServiceClient) AddCommentLikes(ctx context.Context, in *AddCommentLikesReq, opts ...grpc.CallOption) (*AddCommentLikesResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(AddCommentLikesResp)
err := c.cc.Invoke(ctx, CommunityService_AddCommentLikes_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) UpdateCommentLikes(ctx context.Context, in *UpdateCommentLikesReq, opts ...grpc.CallOption) (*UpdateCommentLikesResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(UpdateCommentLikesResp)
err := c.cc.Invoke(ctx, CommunityService_UpdateCommentLikes_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) DelCommentLikes(ctx context.Context, in *DelCommentLikesReq, opts ...grpc.CallOption) (*DelCommentLikesResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(DelCommentLikesResp)
err := c.cc.Invoke(ctx, CommunityService_DelCommentLikes_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) GetCommentLikesById(ctx context.Context, in *GetCommentLikesByIdReq, opts ...grpc.CallOption) (*GetCommentLikesByIdResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(GetCommentLikesByIdResp)
err := c.cc.Invoke(ctx, CommunityService_GetCommentLikesById_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) SearchCommentLikes(ctx context.Context, in *SearchCommentLikesReq, opts ...grpc.CallOption) (*SearchCommentLikesResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(SearchCommentLikesResp)
err := c.cc.Invoke(ctx, CommunityService_SearchCommentLikes_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) AddComments(ctx context.Context, in *AddCommentsReq, opts ...grpc.CallOption) (*AddCommentsResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(AddCommentsResp)
err := c.cc.Invoke(ctx, CommunityService_AddComments_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) UpdateComments(ctx context.Context, in *UpdateCommentsReq, opts ...grpc.CallOption) (*UpdateCommentsResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(UpdateCommentsResp)
err := c.cc.Invoke(ctx, CommunityService_UpdateComments_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) DelComments(ctx context.Context, in *DelCommentsReq, opts ...grpc.CallOption) (*DelCommentsResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(DelCommentsResp)
err := c.cc.Invoke(ctx, CommunityService_DelComments_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) GetCommentsById(ctx context.Context, in *GetCommentsByIdReq, opts ...grpc.CallOption) (*GetCommentsByIdResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(GetCommentsByIdResp)
err := c.cc.Invoke(ctx, CommunityService_GetCommentsById_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) SearchComments(ctx context.Context, in *SearchCommentsReq, opts ...grpc.CallOption) (*SearchCommentsResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(SearchCommentsResp)
err := c.cc.Invoke(ctx, CommunityService_SearchComments_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) AddPostLikes(ctx context.Context, in *AddPostLikesReq, opts ...grpc.CallOption) (*AddPostLikesResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(AddPostLikesResp)
err := c.cc.Invoke(ctx, CommunityService_AddPostLikes_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) UpdatePostLikes(ctx context.Context, in *UpdatePostLikesReq, opts ...grpc.CallOption) (*UpdatePostLikesResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(UpdatePostLikesResp)
err := c.cc.Invoke(ctx, CommunityService_UpdatePostLikes_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) DelPostLikes(ctx context.Context, in *DelPostLikesReq, opts ...grpc.CallOption) (*DelPostLikesResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(DelPostLikesResp)
err := c.cc.Invoke(ctx, CommunityService_DelPostLikes_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) GetPostLikesById(ctx context.Context, in *GetPostLikesByIdReq, opts ...grpc.CallOption) (*GetPostLikesByIdResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(GetPostLikesByIdResp)
err := c.cc.Invoke(ctx, CommunityService_GetPostLikesById_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) SearchPostLikes(ctx context.Context, in *SearchPostLikesReq, opts ...grpc.CallOption) (*SearchPostLikesResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(SearchPostLikesResp)
err := c.cc.Invoke(ctx, CommunityService_SearchPostLikes_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) AddPosts(ctx context.Context, in *AddPostsReq, opts ...grpc.CallOption) (*AddPostsResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(AddPostsResp)
err := c.cc.Invoke(ctx, CommunityService_AddPosts_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) UpdatePosts(ctx context.Context, in *UpdatePostsReq, opts ...grpc.CallOption) (*UpdatePostsResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(UpdatePostsResp)
err := c.cc.Invoke(ctx, CommunityService_UpdatePosts_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) DelPosts(ctx context.Context, in *DelPostsReq, opts ...grpc.CallOption) (*DelPostsResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(DelPostsResp)
err := c.cc.Invoke(ctx, CommunityService_DelPosts_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) GetPostsById(ctx context.Context, in *GetPostsByIdReq, opts ...grpc.CallOption) (*GetPostsByIdResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(GetPostsByIdResp)
err := c.cc.Invoke(ctx, CommunityService_GetPostsById_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *communityServiceClient) SearchPosts(ctx context.Context, in *SearchPostsReq, opts ...grpc.CallOption) (*SearchPostsResp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(SearchPostsResp)
err := c.cc.Invoke(ctx, CommunityService_SearchPosts_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
// CommunityServiceServer is the server API for CommunityService service.
// All implementations must embed UnimplementedCommunityServiceServer
// for forward compatibility.
type CommunityServiceServer interface {
// -----------------------commentLikes-----------------------
AddCommentLikes(context.Context, *AddCommentLikesReq) (*AddCommentLikesResp, error)
UpdateCommentLikes(context.Context, *UpdateCommentLikesReq) (*UpdateCommentLikesResp, error)
DelCommentLikes(context.Context, *DelCommentLikesReq) (*DelCommentLikesResp, error)
GetCommentLikesById(context.Context, *GetCommentLikesByIdReq) (*GetCommentLikesByIdResp, error)
SearchCommentLikes(context.Context, *SearchCommentLikesReq) (*SearchCommentLikesResp, error)
// -----------------------comments-----------------------
AddComments(context.Context, *AddCommentsReq) (*AddCommentsResp, error)
UpdateComments(context.Context, *UpdateCommentsReq) (*UpdateCommentsResp, error)
DelComments(context.Context, *DelCommentsReq) (*DelCommentsResp, error)
GetCommentsById(context.Context, *GetCommentsByIdReq) (*GetCommentsByIdResp, error)
SearchComments(context.Context, *SearchCommentsReq) (*SearchCommentsResp, error)
// -----------------------postLikes-----------------------
AddPostLikes(context.Context, *AddPostLikesReq) (*AddPostLikesResp, error)
UpdatePostLikes(context.Context, *UpdatePostLikesReq) (*UpdatePostLikesResp, error)
DelPostLikes(context.Context, *DelPostLikesReq) (*DelPostLikesResp, error)
GetPostLikesById(context.Context, *GetPostLikesByIdReq) (*GetPostLikesByIdResp, error)
SearchPostLikes(context.Context, *SearchPostLikesReq) (*SearchPostLikesResp, error)
// -----------------------posts-----------------------
AddPosts(context.Context, *AddPostsReq) (*AddPostsResp, error)
UpdatePosts(context.Context, *UpdatePostsReq) (*UpdatePostsResp, error)
DelPosts(context.Context, *DelPostsReq) (*DelPostsResp, error)
GetPostsById(context.Context, *GetPostsByIdReq) (*GetPostsByIdResp, error)
SearchPosts(context.Context, *SearchPostsReq) (*SearchPostsResp, error)
mustEmbedUnimplementedCommunityServiceServer()
}
// UnimplementedCommunityServiceServer must be embedded to have
// forward compatible implementations.
//
// NOTE: this should be embedded by value instead of pointer to avoid a nil
// pointer dereference when methods are called.
type UnimplementedCommunityServiceServer struct{}
func (UnimplementedCommunityServiceServer) AddCommentLikes(context.Context, *AddCommentLikesReq) (*AddCommentLikesResp, error) {
return nil, status.Error(codes.Unimplemented, "method AddCommentLikes not implemented")
}
func (UnimplementedCommunityServiceServer) UpdateCommentLikes(context.Context, *UpdateCommentLikesReq) (*UpdateCommentLikesResp, error) {
return nil, status.Error(codes.Unimplemented, "method UpdateCommentLikes not implemented")
}
func (UnimplementedCommunityServiceServer) DelCommentLikes(context.Context, *DelCommentLikesReq) (*DelCommentLikesResp, error) {
return nil, status.Error(codes.Unimplemented, "method DelCommentLikes not implemented")
}
func (UnimplementedCommunityServiceServer) GetCommentLikesById(context.Context, *GetCommentLikesByIdReq) (*GetCommentLikesByIdResp, error) {
return nil, status.Error(codes.Unimplemented, "method GetCommentLikesById not implemented")
}
func (UnimplementedCommunityServiceServer) SearchCommentLikes(context.Context, *SearchCommentLikesReq) (*SearchCommentLikesResp, error) {
return nil, status.Error(codes.Unimplemented, "method SearchCommentLikes not implemented")
}
func (UnimplementedCommunityServiceServer) AddComments(context.Context, *AddCommentsReq) (*AddCommentsResp, error) {
return nil, status.Error(codes.Unimplemented, "method AddComments not implemented")
}
func (UnimplementedCommunityServiceServer) UpdateComments(context.Context, *UpdateCommentsReq) (*UpdateCommentsResp, error) {
return nil, status.Error(codes.Unimplemented, "method UpdateComments not implemented")
}
func (UnimplementedCommunityServiceServer) DelComments(context.Context, *DelCommentsReq) (*DelCommentsResp, error) {
return nil, status.Error(codes.Unimplemented, "method DelComments not implemented")
}
func (UnimplementedCommunityServiceServer) GetCommentsById(context.Context, *GetCommentsByIdReq) (*GetCommentsByIdResp, error) {
return nil, status.Error(codes.Unimplemented, "method GetCommentsById not implemented")
}
func (UnimplementedCommunityServiceServer) SearchComments(context.Context, *SearchCommentsReq) (*SearchCommentsResp, error) {
return nil, status.Error(codes.Unimplemented, "method SearchComments not implemented")
}
func (UnimplementedCommunityServiceServer) AddPostLikes(context.Context, *AddPostLikesReq) (*AddPostLikesResp, error) {
return nil, status.Error(codes.Unimplemented, "method AddPostLikes not implemented")
}
func (UnimplementedCommunityServiceServer) UpdatePostLikes(context.Context, *UpdatePostLikesReq) (*UpdatePostLikesResp, error) {
return nil, status.Error(codes.Unimplemented, "method UpdatePostLikes not implemented")
}
func (UnimplementedCommunityServiceServer) DelPostLikes(context.Context, *DelPostLikesReq) (*DelPostLikesResp, error) {
return nil, status.Error(codes.Unimplemented, "method DelPostLikes not implemented")
}
func (UnimplementedCommunityServiceServer) GetPostLikesById(context.Context, *GetPostLikesByIdReq) (*GetPostLikesByIdResp, error) {
return nil, status.Error(codes.Unimplemented, "method GetPostLikesById not implemented")
}
func (UnimplementedCommunityServiceServer) SearchPostLikes(context.Context, *SearchPostLikesReq) (*SearchPostLikesResp, error) {
return nil, status.Error(codes.Unimplemented, "method SearchPostLikes not implemented")
}
func (UnimplementedCommunityServiceServer) AddPosts(context.Context, *AddPostsReq) (*AddPostsResp, error) {
return nil, status.Error(codes.Unimplemented, "method AddPosts not implemented")
}
func (UnimplementedCommunityServiceServer) UpdatePosts(context.Context, *UpdatePostsReq) (*UpdatePostsResp, error) {
return nil, status.Error(codes.Unimplemented, "method UpdatePosts not implemented")
}
func (UnimplementedCommunityServiceServer) DelPosts(context.Context, *DelPostsReq) (*DelPostsResp, error) {
return nil, status.Error(codes.Unimplemented, "method DelPosts not implemented")
}
func (UnimplementedCommunityServiceServer) GetPostsById(context.Context, *GetPostsByIdReq) (*GetPostsByIdResp, error) {
return nil, status.Error(codes.Unimplemented, "method GetPostsById not implemented")
}
func (UnimplementedCommunityServiceServer) SearchPosts(context.Context, *SearchPostsReq) (*SearchPostsResp, error) {
return nil, status.Error(codes.Unimplemented, "method SearchPosts not implemented")
}
func (UnimplementedCommunityServiceServer) mustEmbedUnimplementedCommunityServiceServer() {}
func (UnimplementedCommunityServiceServer) testEmbeddedByValue() {}
// UnsafeCommunityServiceServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to CommunityServiceServer will
// result in compilation errors.
type UnsafeCommunityServiceServer interface {
mustEmbedUnimplementedCommunityServiceServer()
}
func RegisterCommunityServiceServer(s grpc.ServiceRegistrar, srv CommunityServiceServer) {
// If the following call panics, it indicates UnimplementedCommunityServiceServer was
// embedded by pointer and is nil. This will cause panics if an
// unimplemented method is ever invoked, so we test this at initialization
// time to prevent it from happening at runtime later due to I/O.
if t, ok := srv.(interface{ testEmbeddedByValue() }); ok {
t.testEmbeddedByValue()
}
s.RegisterService(&CommunityService_ServiceDesc, srv)
}
func _CommunityService_AddCommentLikes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(AddCommentLikesReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).AddCommentLikes(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_AddCommentLikes_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).AddCommentLikes(ctx, req.(*AddCommentLikesReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_UpdateCommentLikes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(UpdateCommentLikesReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).UpdateCommentLikes(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_UpdateCommentLikes_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).UpdateCommentLikes(ctx, req.(*UpdateCommentLikesReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_DelCommentLikes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(DelCommentLikesReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).DelCommentLikes(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_DelCommentLikes_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).DelCommentLikes(ctx, req.(*DelCommentLikesReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_GetCommentLikesById_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetCommentLikesByIdReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).GetCommentLikesById(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_GetCommentLikesById_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).GetCommentLikesById(ctx, req.(*GetCommentLikesByIdReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_SearchCommentLikes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SearchCommentLikesReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).SearchCommentLikes(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_SearchCommentLikes_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).SearchCommentLikes(ctx, req.(*SearchCommentLikesReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_AddComments_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(AddCommentsReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).AddComments(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_AddComments_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).AddComments(ctx, req.(*AddCommentsReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_UpdateComments_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(UpdateCommentsReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).UpdateComments(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_UpdateComments_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).UpdateComments(ctx, req.(*UpdateCommentsReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_DelComments_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(DelCommentsReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).DelComments(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_DelComments_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).DelComments(ctx, req.(*DelCommentsReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_GetCommentsById_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetCommentsByIdReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).GetCommentsById(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_GetCommentsById_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).GetCommentsById(ctx, req.(*GetCommentsByIdReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_SearchComments_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SearchCommentsReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).SearchComments(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_SearchComments_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).SearchComments(ctx, req.(*SearchCommentsReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_AddPostLikes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(AddPostLikesReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).AddPostLikes(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_AddPostLikes_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).AddPostLikes(ctx, req.(*AddPostLikesReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_UpdatePostLikes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(UpdatePostLikesReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).UpdatePostLikes(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_UpdatePostLikes_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).UpdatePostLikes(ctx, req.(*UpdatePostLikesReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_DelPostLikes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(DelPostLikesReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).DelPostLikes(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_DelPostLikes_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).DelPostLikes(ctx, req.(*DelPostLikesReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_GetPostLikesById_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetPostLikesByIdReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).GetPostLikesById(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_GetPostLikesById_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).GetPostLikesById(ctx, req.(*GetPostLikesByIdReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_SearchPostLikes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SearchPostLikesReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).SearchPostLikes(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_SearchPostLikes_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).SearchPostLikes(ctx, req.(*SearchPostLikesReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_AddPosts_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(AddPostsReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).AddPosts(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_AddPosts_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).AddPosts(ctx, req.(*AddPostsReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_UpdatePosts_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(UpdatePostsReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).UpdatePosts(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_UpdatePosts_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).UpdatePosts(ctx, req.(*UpdatePostsReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_DelPosts_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(DelPostsReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).DelPosts(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_DelPosts_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).DelPosts(ctx, req.(*DelPostsReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_GetPostsById_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetPostsByIdReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).GetPostsById(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_GetPostsById_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).GetPostsById(ctx, req.(*GetPostsByIdReq))
}
return interceptor(ctx, in, info, handler)
}
func _CommunityService_SearchPosts_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SearchPostsReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(CommunityServiceServer).SearchPosts(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: CommunityService_SearchPosts_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(CommunityServiceServer).SearchPosts(ctx, req.(*SearchPostsReq))
}
return interceptor(ctx, in, info, handler)
}
// CommunityService_ServiceDesc is the grpc.ServiceDesc for CommunityService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var CommunityService_ServiceDesc = grpc.ServiceDesc{
ServiceName: "pb.communityService",
HandlerType: (*CommunityServiceServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "AddCommentLikes",
Handler: _CommunityService_AddCommentLikes_Handler,
},
{
MethodName: "UpdateCommentLikes",
Handler: _CommunityService_UpdateCommentLikes_Handler,
},
{
MethodName: "DelCommentLikes",
Handler: _CommunityService_DelCommentLikes_Handler,
},
{
MethodName: "GetCommentLikesById",
Handler: _CommunityService_GetCommentLikesById_Handler,
},
{
MethodName: "SearchCommentLikes",
Handler: _CommunityService_SearchCommentLikes_Handler,
},
{
MethodName: "AddComments",
Handler: _CommunityService_AddComments_Handler,
},
{
MethodName: "UpdateComments",
Handler: _CommunityService_UpdateComments_Handler,
},
{
MethodName: "DelComments",
Handler: _CommunityService_DelComments_Handler,
},
{
MethodName: "GetCommentsById",
Handler: _CommunityService_GetCommentsById_Handler,
},
{
MethodName: "SearchComments",
Handler: _CommunityService_SearchComments_Handler,
},
{
MethodName: "AddPostLikes",
Handler: _CommunityService_AddPostLikes_Handler,
},
{
MethodName: "UpdatePostLikes",
Handler: _CommunityService_UpdatePostLikes_Handler,
},
{
MethodName: "DelPostLikes",
Handler: _CommunityService_DelPostLikes_Handler,
},
{
MethodName: "GetPostLikesById",
Handler: _CommunityService_GetPostLikesById_Handler,
},
{
MethodName: "SearchPostLikes",
Handler: _CommunityService_SearchPostLikes_Handler,
},
{
MethodName: "AddPosts",
Handler: _CommunityService_AddPosts_Handler,
},
{
MethodName: "UpdatePosts",
Handler: _CommunityService_UpdatePosts_Handler,
},
{
MethodName: "DelPosts",
Handler: _CommunityService_DelPosts_Handler,
},
{
MethodName: "GetPostsById",
Handler: _CommunityService_GetPostsById_Handler,
},
{
MethodName: "SearchPosts",
Handler: _CommunityService_SearchPosts_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "community.proto",
}