// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.2.0
// - protoc             v3.21.12
// source: world.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.32.0 or later.
const _ = grpc.SupportPackageIsVersion7

// WorldServiceClient is the client API for WorldService 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 WorldServiceClient interface {
	//WorldPostSubmit 世界圈帖子发布
	WorldPostSubmit(ctx context.Context, in *WorldPostSubmitReq, opts ...grpc.CallOption) (*WorldPostSubmitResp, error)
}

type worldServiceClient struct {
	cc grpc.ClientConnInterface
}

func NewWorldServiceClient(cc grpc.ClientConnInterface) WorldServiceClient {
	return &worldServiceClient{cc}
}

func (c *worldServiceClient) WorldPostSubmit(ctx context.Context, in *WorldPostSubmitReq, opts ...grpc.CallOption) (*WorldPostSubmitResp, error) {
	out := new(WorldPostSubmitResp)
	err := c.cc.Invoke(ctx, "/pb.worldService/WorldPostSubmit", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// WorldServiceServer is the server API for WorldService service.
// All implementations must embed UnimplementedWorldServiceServer
// for forward compatibility
type WorldServiceServer interface {
	//WorldPostSubmit 世界圈帖子发布
	WorldPostSubmit(context.Context, *WorldPostSubmitReq) (*WorldPostSubmitResp, error)
	mustEmbedUnimplementedWorldServiceServer()
}

// UnimplementedWorldServiceServer must be embedded to have forward compatible implementations.
type UnimplementedWorldServiceServer struct {
}

func (UnimplementedWorldServiceServer) WorldPostSubmit(context.Context, *WorldPostSubmitReq) (*WorldPostSubmitResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method WorldPostSubmit not implemented")
}
func (UnimplementedWorldServiceServer) mustEmbedUnimplementedWorldServiceServer() {}

// UnsafeWorldServiceServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to WorldServiceServer will
// result in compilation errors.
type UnsafeWorldServiceServer interface {
	mustEmbedUnimplementedWorldServiceServer()
}

func RegisterWorldServiceServer(s grpc.ServiceRegistrar, srv WorldServiceServer) {
	s.RegisterService(&WorldService_ServiceDesc, srv)
}

func _WorldService_WorldPostSubmit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(WorldPostSubmitReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(WorldServiceServer).WorldPostSubmit(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/pb.worldService/WorldPostSubmit",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(WorldServiceServer).WorldPostSubmit(ctx, req.(*WorldPostSubmitReq))
	}
	return interceptor(ctx, in, info, handler)
}

// WorldService_ServiceDesc is the grpc.ServiceDesc for WorldService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var WorldService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "pb.worldService",
	HandlerType: (*WorldServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "WorldPostSubmit",
			Handler:    _WorldService_WorldPostSubmit_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "world.proto",
}
