v1

package
v1.0.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 24, 2024 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var BizOrderService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "biz_order.v1.BizOrderService",
	HandlerType: (*BizOrderServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateOrder",
			Handler:    _BizOrderService_CreateOrder_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "biz_order/v1/biz_order.proto",
}

BizOrderService_ServiceDesc is the grpc.ServiceDesc for BizOrderService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_biz_order_v1_biz_order_proto protoreflect.FileDescriptor

Functions

func RegisterBizOrderServiceServer

func RegisterBizOrderServiceServer(s grpc.ServiceRegistrar, srv BizOrderServiceServer)

Types

type BizOrderServiceClient

type BizOrderServiceClient interface {
	// 生成订单
	CreateOrder(ctx context.Context, in *CreateOrderRequest, opts ...grpc.CallOption) (*base.OperateReply, error)
}

BizOrderServiceClient is the client API for BizOrderService 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 BizOrderServiceServer

type BizOrderServiceServer interface {
	// 生成订单
	CreateOrder(context.Context, *CreateOrderRequest) (*base.OperateReply, error)
	// contains filtered or unexported methods
}

BizOrderServiceServer is the server API for BizOrderService service. All implementations must embed UnimplementedBizOrderServiceServer for forward compatibility

type CreateOrderReply

type CreateOrderReply struct {
	Response *CreateOrderResponse `protobuf:"bytes,1,opt,name=Response,proto3" json:"Response,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateOrderReply) Descriptor deprecated

func (*CreateOrderReply) Descriptor() ([]byte, []int)

Deprecated: Use CreateOrderReply.ProtoReflect.Descriptor instead.

func (*CreateOrderReply) GetResponse

func (x *CreateOrderReply) GetResponse() *CreateOrderResponse

func (*CreateOrderReply) ProtoMessage

func (*CreateOrderReply) ProtoMessage()

func (*CreateOrderReply) ProtoReflect

func (x *CreateOrderReply) ProtoReflect() protoreflect.Message

func (*CreateOrderReply) Reset

func (x *CreateOrderReply) Reset()

func (*CreateOrderReply) String

func (x *CreateOrderReply) String() string

func (*CreateOrderReply) Validate

func (m *CreateOrderReply) Validate() error

Validate checks the field values on CreateOrderReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*CreateOrderReply) ValidateAll

func (m *CreateOrderReply) ValidateAll() error

ValidateAll checks the field values on CreateOrderReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CreateOrderReplyMultiError, or nil if none found.

type CreateOrderReplyMultiError

type CreateOrderReplyMultiError []error

CreateOrderReplyMultiError is an error wrapping multiple validation errors returned by CreateOrderReply.ValidateAll() if the designated constraints aren't met.

func (CreateOrderReplyMultiError) AllErrors

func (m CreateOrderReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (CreateOrderReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type CreateOrderReplyValidationError

type CreateOrderReplyValidationError struct {
	// contains filtered or unexported fields
}

CreateOrderReplyValidationError is the validation error returned by CreateOrderReply.Validate if the designated constraints aren't met.

func (CreateOrderReplyValidationError) Cause

Cause function returns cause value.

func (CreateOrderReplyValidationError) Error

Error satisfies the builtin error interface

func (CreateOrderReplyValidationError) ErrorName

ErrorName returns error name.

func (CreateOrderReplyValidationError) Field

Field function returns field value.

func (CreateOrderReplyValidationError) Key

Key function returns key value.

func (CreateOrderReplyValidationError) Reason

Reason function returns reason value.

type CreateOrderRequest

type CreateOrderRequest struct {
	RequestID     string `protobuf:"bytes,1,opt,name=RequestID,proto3" json:"RequestID,omitempty"`
	UserID        int64  `protobuf:"varint,2,opt,name=UserID,proto3" json:"UserID,omitempty"`               //订单用户ID
	GoodsID       int64  `protobuf:"varint,3,opt,name=GoodsID,proto3" json:"GoodsID,omitempty"`             //购买的商品ID
	GoodsNumber   int32  `protobuf:"varint,4,opt,name=GoodsNumber,proto3" json:"GoodsNumber,omitempty"`     //购买的商品数量
	PaymentAmount int32  `protobuf:"varint,5,opt,name=PaymentAmount,proto3" json:"PaymentAmount,omitempty"` //支付的金额
	// contains filtered or unexported fields
}

func (*CreateOrderRequest) Descriptor deprecated

func (*CreateOrderRequest) Descriptor() ([]byte, []int)

Deprecated: Use CreateOrderRequest.ProtoReflect.Descriptor instead.

func (*CreateOrderRequest) GetGoodsID

func (x *CreateOrderRequest) GetGoodsID() int64

func (*CreateOrderRequest) GetGoodsNumber

func (x *CreateOrderRequest) GetGoodsNumber() int32

func (*CreateOrderRequest) GetPaymentAmount

func (x *CreateOrderRequest) GetPaymentAmount() int32

func (*CreateOrderRequest) GetRequestID

func (x *CreateOrderRequest) GetRequestID() string

func (*CreateOrderRequest) GetUserID added in v1.0.7

func (x *CreateOrderRequest) GetUserID() int64

func (*CreateOrderRequest) ProtoMessage

func (*CreateOrderRequest) ProtoMessage()

func (*CreateOrderRequest) ProtoReflect

func (x *CreateOrderRequest) ProtoReflect() protoreflect.Message

func (*CreateOrderRequest) Reset

func (x *CreateOrderRequest) Reset()

func (*CreateOrderRequest) String

func (x *CreateOrderRequest) String() string

func (*CreateOrderRequest) Validate

func (m *CreateOrderRequest) Validate() error

Validate checks the field values on CreateOrderRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*CreateOrderRequest) ValidateAll

func (m *CreateOrderRequest) ValidateAll() error

ValidateAll checks the field values on CreateOrderRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CreateOrderRequestMultiError, or nil if none found.

type CreateOrderRequestMultiError

type CreateOrderRequestMultiError []error

CreateOrderRequestMultiError is an error wrapping multiple validation errors returned by CreateOrderRequest.ValidateAll() if the designated constraints aren't met.

func (CreateOrderRequestMultiError) AllErrors

func (m CreateOrderRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (CreateOrderRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type CreateOrderRequestValidationError

type CreateOrderRequestValidationError struct {
	// contains filtered or unexported fields
}

CreateOrderRequestValidationError is the validation error returned by CreateOrderRequest.Validate if the designated constraints aren't met.

func (CreateOrderRequestValidationError) Cause

Cause function returns cause value.

func (CreateOrderRequestValidationError) Error

Error satisfies the builtin error interface

func (CreateOrderRequestValidationError) ErrorName

ErrorName returns error name.

func (CreateOrderRequestValidationError) Field

Field function returns field value.

func (CreateOrderRequestValidationError) Key

Key function returns key value.

func (CreateOrderRequestValidationError) Reason

Reason function returns reason value.

type CreateOrderResponse

type CreateOrderResponse struct {
	RequestID string      `protobuf:"bytes,1,opt,name=RequestID,proto3" json:"RequestID,omitempty"`
	Error     *base.Error `protobuf:"bytes,2,opt,name=Error,proto3" json:"Error,omitempty"`
	OrderNo   string      `protobuf:"bytes,3,opt,name=OrderNo,proto3" json:"OrderNo,omitempty"` //订单编号
	// contains filtered or unexported fields
}

func (*CreateOrderResponse) Descriptor deprecated

func (*CreateOrderResponse) Descriptor() ([]byte, []int)

Deprecated: Use CreateOrderResponse.ProtoReflect.Descriptor instead.

func (*CreateOrderResponse) GetError

func (x *CreateOrderResponse) GetError() *base.Error

func (*CreateOrderResponse) GetOrderNo

func (x *CreateOrderResponse) GetOrderNo() string

func (*CreateOrderResponse) GetRequestID

func (x *CreateOrderResponse) GetRequestID() string

func (*CreateOrderResponse) ProtoMessage

func (*CreateOrderResponse) ProtoMessage()

func (*CreateOrderResponse) ProtoReflect

func (x *CreateOrderResponse) ProtoReflect() protoreflect.Message

func (*CreateOrderResponse) Reset

func (x *CreateOrderResponse) Reset()

func (*CreateOrderResponse) String

func (x *CreateOrderResponse) String() string

func (*CreateOrderResponse) Validate

func (m *CreateOrderResponse) Validate() error

Validate checks the field values on CreateOrderResponse with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*CreateOrderResponse) ValidateAll

func (m *CreateOrderResponse) ValidateAll() error

ValidateAll checks the field values on CreateOrderResponse with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CreateOrderResponseMultiError, or nil if none found.

type CreateOrderResponseMultiError

type CreateOrderResponseMultiError []error

CreateOrderResponseMultiError is an error wrapping multiple validation errors returned by CreateOrderResponse.ValidateAll() if the designated constraints aren't met.

func (CreateOrderResponseMultiError) AllErrors

func (m CreateOrderResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (CreateOrderResponseMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type CreateOrderResponseValidationError

type CreateOrderResponseValidationError struct {
	// contains filtered or unexported fields
}

CreateOrderResponseValidationError is the validation error returned by CreateOrderResponse.Validate if the designated constraints aren't met.

func (CreateOrderResponseValidationError) Cause

Cause function returns cause value.

func (CreateOrderResponseValidationError) Error

Error satisfies the builtin error interface

func (CreateOrderResponseValidationError) ErrorName

ErrorName returns error name.

func (CreateOrderResponseValidationError) Field

Field function returns field value.

func (CreateOrderResponseValidationError) Key

Key function returns key value.

func (CreateOrderResponseValidationError) Reason

Reason function returns reason value.

type UnimplementedBizOrderServiceServer

type UnimplementedBizOrderServiceServer struct {
}

UnimplementedBizOrderServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedBizOrderServiceServer) CreateOrder

type UnsafeBizOrderServiceServer

type UnsafeBizOrderServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeBizOrderServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to BizOrderServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL