// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.6.2
// - protoc             v7.35.1
// source: module/ec/order/proto/summary.proto

package order

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 (
	Summary_QuickCreateByProduct_FullMethodName = "/order.Summary/QuickCreateByProduct"
	Summary_Submit_FullMethodName               = "/order.Summary/Submit"
	Summary_Check_FullMethodName                = "/order.Summary/Check"
	Summary_Get_FullMethodName                  = "/order.Summary/Get"
	Summary_List_FullMethodName                 = "/order.Summary/List"
	Summary_Confirm_FullMethodName              = "/order.Summary/Confirm"
	Summary_Cancel_FullMethodName               = "/order.Summary/Cancel"
	Summary_SimulatePay_FullMethodName          = "/order.Summary/SimulatePay"
	Summary_SimulateShipments_FullMethodName    = "/order.Summary/SimulateShipments"
	Summary_SimulateReceiving_FullMethodName    = "/order.Summary/SimulateReceiving"
)

// SummaryClient is the client API for Summary 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.
//
// Order(订单)微服务-订单模块
// C端模块
type SummaryClient interface {
	// 快速创建一个店铺订单
	QuickCreateByProduct(ctx context.Context, in *QuickCreateByProductRequest, opts ...grpc.CallOption) (*OrderStatusReply, error)
	// 将购物车的数据提交生成订单
	Submit(ctx context.Context, in *SubmitRequest, opts ...grpc.CallOption) (*OrderStatusReply, error)
	// 检测是否有未确认及付款的订单
	Check(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*OrderStatusReply, error)
	// 获取一个订单的详情数据
	Get(ctx context.Context, in *OrderIdentRequest, opts ...grpc.CallOption) (*SummaryGetReply, error)
	// 根据不同的类型获取我的订单列表
	List(ctx context.Context, in *SummaryListRequest, opts ...grpc.CallOption) (*SummaryListReply, error)
	// 确认订单，物流，优惠卷等其它信息
	Confirm(ctx context.Context, in *ConfirmRequest, opts ...grpc.CallOption) (*ConfirmReply, error)
	// 取消订单
	Cancel(ctx context.Context, in *CancelRequest, opts ...grpc.CallOption) (*OrderStatusReply, error)
	// 模拟支付
	SimulatePay(ctx context.Context, in *SimulatePayRequest, opts ...grpc.CallOption) (*OrderStatusReply, error)
	// 模拟发货
	SimulateShipments(ctx context.Context, in *SimulateShipmentsRequest, opts ...grpc.CallOption) (*OrderStatusReply, error)
	// 模拟收货
	SimulateReceiving(ctx context.Context, in *OrderIdentRequest, opts ...grpc.CallOption) (*OrderStatusReply, error)
}

type summaryClient struct {
	cc grpc.ClientConnInterface
}

func NewSummaryClient(cc grpc.ClientConnInterface) SummaryClient {
	return &summaryClient{cc}
}

func (c *summaryClient) QuickCreateByProduct(ctx context.Context, in *QuickCreateByProductRequest, opts ...grpc.CallOption) (*OrderStatusReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(OrderStatusReply)
	err := c.cc.Invoke(ctx, Summary_QuickCreateByProduct_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *summaryClient) Submit(ctx context.Context, in *SubmitRequest, opts ...grpc.CallOption) (*OrderStatusReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(OrderStatusReply)
	err := c.cc.Invoke(ctx, Summary_Submit_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *summaryClient) Check(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*OrderStatusReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(OrderStatusReply)
	err := c.cc.Invoke(ctx, Summary_Check_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *summaryClient) Get(ctx context.Context, in *OrderIdentRequest, opts ...grpc.CallOption) (*SummaryGetReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(SummaryGetReply)
	err := c.cc.Invoke(ctx, Summary_Get_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *summaryClient) List(ctx context.Context, in *SummaryListRequest, opts ...grpc.CallOption) (*SummaryListReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(SummaryListReply)
	err := c.cc.Invoke(ctx, Summary_List_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *summaryClient) Confirm(ctx context.Context, in *ConfirmRequest, opts ...grpc.CallOption) (*ConfirmReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(ConfirmReply)
	err := c.cc.Invoke(ctx, Summary_Confirm_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *summaryClient) Cancel(ctx context.Context, in *CancelRequest, opts ...grpc.CallOption) (*OrderStatusReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(OrderStatusReply)
	err := c.cc.Invoke(ctx, Summary_Cancel_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *summaryClient) SimulatePay(ctx context.Context, in *SimulatePayRequest, opts ...grpc.CallOption) (*OrderStatusReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(OrderStatusReply)
	err := c.cc.Invoke(ctx, Summary_SimulatePay_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *summaryClient) SimulateShipments(ctx context.Context, in *SimulateShipmentsRequest, opts ...grpc.CallOption) (*OrderStatusReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(OrderStatusReply)
	err := c.cc.Invoke(ctx, Summary_SimulateShipments_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *summaryClient) SimulateReceiving(ctx context.Context, in *OrderIdentRequest, opts ...grpc.CallOption) (*OrderStatusReply, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(OrderStatusReply)
	err := c.cc.Invoke(ctx, Summary_SimulateReceiving_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// SummaryServer is the server API for Summary service.
// All implementations should embed UnimplementedSummaryServer
// for forward compatibility.
//
// Order(订单)微服务-订单模块
// C端模块
type SummaryServer interface {
	// 快速创建一个店铺订单
	QuickCreateByProduct(context.Context, *QuickCreateByProductRequest) (*OrderStatusReply, error)
	// 将购物车的数据提交生成订单
	Submit(context.Context, *SubmitRequest) (*OrderStatusReply, error)
	// 检测是否有未确认及付款的订单
	Check(context.Context, *Empty) (*OrderStatusReply, error)
	// 获取一个订单的详情数据
	Get(context.Context, *OrderIdentRequest) (*SummaryGetReply, error)
	// 根据不同的类型获取我的订单列表
	List(context.Context, *SummaryListRequest) (*SummaryListReply, error)
	// 确认订单，物流，优惠卷等其它信息
	Confirm(context.Context, *ConfirmRequest) (*ConfirmReply, error)
	// 取消订单
	Cancel(context.Context, *CancelRequest) (*OrderStatusReply, error)
	// 模拟支付
	SimulatePay(context.Context, *SimulatePayRequest) (*OrderStatusReply, error)
	// 模拟发货
	SimulateShipments(context.Context, *SimulateShipmentsRequest) (*OrderStatusReply, error)
	// 模拟收货
	SimulateReceiving(context.Context, *OrderIdentRequest) (*OrderStatusReply, error)
}

// UnimplementedSummaryServer should 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 UnimplementedSummaryServer struct{}

func (UnimplementedSummaryServer) QuickCreateByProduct(context.Context, *QuickCreateByProductRequest) (*OrderStatusReply, error) {
	return nil, status.Error(codes.Unimplemented, "method QuickCreateByProduct not implemented")
}
func (UnimplementedSummaryServer) Submit(context.Context, *SubmitRequest) (*OrderStatusReply, error) {
	return nil, status.Error(codes.Unimplemented, "method Submit not implemented")
}
func (UnimplementedSummaryServer) Check(context.Context, *Empty) (*OrderStatusReply, error) {
	return nil, status.Error(codes.Unimplemented, "method Check not implemented")
}
func (UnimplementedSummaryServer) Get(context.Context, *OrderIdentRequest) (*SummaryGetReply, error) {
	return nil, status.Error(codes.Unimplemented, "method Get not implemented")
}
func (UnimplementedSummaryServer) List(context.Context, *SummaryListRequest) (*SummaryListReply, error) {
	return nil, status.Error(codes.Unimplemented, "method List not implemented")
}
func (UnimplementedSummaryServer) Confirm(context.Context, *ConfirmRequest) (*ConfirmReply, error) {
	return nil, status.Error(codes.Unimplemented, "method Confirm not implemented")
}
func (UnimplementedSummaryServer) Cancel(context.Context, *CancelRequest) (*OrderStatusReply, error) {
	return nil, status.Error(codes.Unimplemented, "method Cancel not implemented")
}
func (UnimplementedSummaryServer) SimulatePay(context.Context, *SimulatePayRequest) (*OrderStatusReply, error) {
	return nil, status.Error(codes.Unimplemented, "method SimulatePay not implemented")
}
func (UnimplementedSummaryServer) SimulateShipments(context.Context, *SimulateShipmentsRequest) (*OrderStatusReply, error) {
	return nil, status.Error(codes.Unimplemented, "method SimulateShipments not implemented")
}
func (UnimplementedSummaryServer) SimulateReceiving(context.Context, *OrderIdentRequest) (*OrderStatusReply, error) {
	return nil, status.Error(codes.Unimplemented, "method SimulateReceiving not implemented")
}
func (UnimplementedSummaryServer) testEmbeddedByValue() {}

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

func RegisterSummaryServer(s grpc.ServiceRegistrar, srv SummaryServer) {
	// If the following call panics, it indicates UnimplementedSummaryServer 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(&Summary_ServiceDesc, srv)
}

func _Summary_QuickCreateByProduct_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(QuickCreateByProductRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).QuickCreateByProduct(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_QuickCreateByProduct_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).QuickCreateByProduct(ctx, req.(*QuickCreateByProductRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Summary_Submit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(SubmitRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).Submit(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_Submit_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).Submit(ctx, req.(*SubmitRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Summary_Check_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(Empty)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).Check(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_Check_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).Check(ctx, req.(*Empty))
	}
	return interceptor(ctx, in, info, handler)
}

func _Summary_Get_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(OrderIdentRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).Get(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_Get_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).Get(ctx, req.(*OrderIdentRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Summary_List_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(SummaryListRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).List(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_List_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).List(ctx, req.(*SummaryListRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Summary_Confirm_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ConfirmRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).Confirm(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_Confirm_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).Confirm(ctx, req.(*ConfirmRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Summary_Cancel_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(CancelRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).Cancel(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_Cancel_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).Cancel(ctx, req.(*CancelRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Summary_SimulatePay_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(SimulatePayRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).SimulatePay(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_SimulatePay_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).SimulatePay(ctx, req.(*SimulatePayRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Summary_SimulateShipments_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(SimulateShipmentsRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).SimulateShipments(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_SimulateShipments_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).SimulateShipments(ctx, req.(*SimulateShipmentsRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _Summary_SimulateReceiving_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(OrderIdentRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(SummaryServer).SimulateReceiving(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: Summary_SimulateReceiving_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(SummaryServer).SimulateReceiving(ctx, req.(*OrderIdentRequest))
	}
	return interceptor(ctx, in, info, handler)
}

// Summary_ServiceDesc is the grpc.ServiceDesc for Summary service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var Summary_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "order.Summary",
	HandlerType: (*SummaryServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "QuickCreateByProduct",
			Handler:    _Summary_QuickCreateByProduct_Handler,
		},
		{
			MethodName: "Submit",
			Handler:    _Summary_Submit_Handler,
		},
		{
			MethodName: "Check",
			Handler:    _Summary_Check_Handler,
		},
		{
			MethodName: "Get",
			Handler:    _Summary_Get_Handler,
		},
		{
			MethodName: "List",
			Handler:    _Summary_List_Handler,
		},
		{
			MethodName: "Confirm",
			Handler:    _Summary_Confirm_Handler,
		},
		{
			MethodName: "Cancel",
			Handler:    _Summary_Cancel_Handler,
		},
		{
			MethodName: "SimulatePay",
			Handler:    _Summary_SimulatePay_Handler,
		},
		{
			MethodName: "SimulateShipments",
			Handler:    _Summary_SimulateShipments_Handler,
		},
		{
			MethodName: "SimulateReceiving",
			Handler:    _Summary_SimulateReceiving_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "module/ec/order/proto/summary.proto",
}
