代码拉取完成,页面将自动刷新
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.2.0
// - protoc v3.19.1
// source: client-web/v1/goods/client-goods.proto
package client_goods
import (
context "context"
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
base "https://gitee.com/xiaoluo_1024/tcc_base_pb/base"
)
// 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
// GoodsServiceClient is the client API for GoodsService 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 GoodsServiceClient interface {
//购买商品
BuyGoods(ctx context.Context, in *BuyGoodsRequest, opts ...grpc.CallOption) (*base.OperateReply, error)
}
type goodsServiceClient struct {
cc grpc.ClientConnInterface
}
func NewGoodsServiceClient(cc grpc.ClientConnInterface) GoodsServiceClient {
return &goodsServiceClient{cc}
}
func (c *goodsServiceClient) BuyGoods(ctx context.Context, in *BuyGoodsRequest, opts ...grpc.CallOption) (*base.OperateReply, error) {
out := new(base.OperateReply)
err := c.cc.Invoke(ctx, "/client_web.v1.goods.GoodsService/BuyGoods", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// GoodsServiceServer is the server API for GoodsService service.
// All implementations must embed UnimplementedGoodsServiceServer
// for forward compatibility
type GoodsServiceServer interface {
//购买商品
BuyGoods(context.Context, *BuyGoodsRequest) (*base.OperateReply, error)
mustEmbedUnimplementedGoodsServiceServer()
}
// UnimplementedGoodsServiceServer must be embedded to have forward compatible implementations.
type UnimplementedGoodsServiceServer struct {
}
func (UnimplementedGoodsServiceServer) BuyGoods(context.Context, *BuyGoodsRequest) (*base.OperateReply, error) {
return nil, status.Errorf(codes.Unimplemented, "method BuyGoods not implemented")
}
func (UnimplementedGoodsServiceServer) mustEmbedUnimplementedGoodsServiceServer() {}
// UnsafeGoodsServiceServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to GoodsServiceServer will
// result in compilation errors.
type UnsafeGoodsServiceServer interface {
mustEmbedUnimplementedGoodsServiceServer()
}
func RegisterGoodsServiceServer(s grpc.ServiceRegistrar, srv GoodsServiceServer) {
s.RegisterService(&GoodsService_ServiceDesc, srv)
}
func _GoodsService_BuyGoods_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(BuyGoodsRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(GoodsServiceServer).BuyGoods(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/client_web.v1.goods.GoodsService/BuyGoods",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(GoodsServiceServer).BuyGoods(ctx, req.(*BuyGoodsRequest))
}
return interceptor(ctx, in, info, handler)
}
// GoodsService_ServiceDesc is the grpc.ServiceDesc for GoodsService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var GoodsService_ServiceDesc = grpc.ServiceDesc{
ServiceName: "client_web.v1.goods.GoodsService",
HandlerType: (*GoodsServiceServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "BuyGoods",
Handler: _GoodsService_BuyGoods_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "client-web/v1/goods/client-goods.proto",
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。