Documentation ¶
Index ¶
- Variables
- func RegisterBizOrderServiceServer(s grpc.ServiceRegistrar, srv BizOrderServiceServer)
- type BizOrderServiceClient
- type BizOrderServiceServer
- type CreateOrderReply
- func (*CreateOrderReply) Descriptor() ([]byte, []int)deprecated
- func (x *CreateOrderReply) GetResponse() *CreateOrderResponse
- func (*CreateOrderReply) ProtoMessage()
- func (x *CreateOrderReply) ProtoReflect() protoreflect.Message
- func (x *CreateOrderReply) Reset()
- func (x *CreateOrderReply) String() string
- func (m *CreateOrderReply) Validate() error
- func (m *CreateOrderReply) ValidateAll() error
- type CreateOrderReplyMultiError
- type CreateOrderReplyValidationError
- func (e CreateOrderReplyValidationError) Cause() error
- func (e CreateOrderReplyValidationError) Error() string
- func (e CreateOrderReplyValidationError) ErrorName() string
- func (e CreateOrderReplyValidationError) Field() string
- func (e CreateOrderReplyValidationError) Key() bool
- func (e CreateOrderReplyValidationError) Reason() string
- type CreateOrderRequest
- func (*CreateOrderRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateOrderRequest) GetGoodsID() int64
- func (x *CreateOrderRequest) GetGoodsNumber() int32
- func (x *CreateOrderRequest) GetPaymentAmount() int32
- func (x *CreateOrderRequest) GetRequestID() string
- func (x *CreateOrderRequest) GetUserID() int64
- func (*CreateOrderRequest) ProtoMessage()
- func (x *CreateOrderRequest) ProtoReflect() protoreflect.Message
- func (x *CreateOrderRequest) Reset()
- func (x *CreateOrderRequest) String() string
- func (m *CreateOrderRequest) Validate() error
- func (m *CreateOrderRequest) ValidateAll() error
- type CreateOrderRequestMultiError
- type CreateOrderRequestValidationError
- func (e CreateOrderRequestValidationError) Cause() error
- func (e CreateOrderRequestValidationError) Error() string
- func (e CreateOrderRequestValidationError) ErrorName() string
- func (e CreateOrderRequestValidationError) Field() string
- func (e CreateOrderRequestValidationError) Key() bool
- func (e CreateOrderRequestValidationError) Reason() string
- type CreateOrderResponse
- func (*CreateOrderResponse) Descriptor() ([]byte, []int)deprecated
- func (x *CreateOrderResponse) GetError() *base.Error
- func (x *CreateOrderResponse) GetOrderNo() string
- func (x *CreateOrderResponse) GetRequestID() string
- func (*CreateOrderResponse) ProtoMessage()
- func (x *CreateOrderResponse) ProtoReflect() protoreflect.Message
- func (x *CreateOrderResponse) Reset()
- func (x *CreateOrderResponse) String() string
- func (m *CreateOrderResponse) Validate() error
- func (m *CreateOrderResponse) ValidateAll() error
- type CreateOrderResponseMultiError
- type CreateOrderResponseValidationError
- func (e CreateOrderResponseValidationError) Cause() error
- func (e CreateOrderResponseValidationError) Error() string
- func (e CreateOrderResponseValidationError) ErrorName() string
- func (e CreateOrderResponseValidationError) Field() string
- func (e CreateOrderResponseValidationError) Key() bool
- func (e CreateOrderResponseValidationError) Reason() string
- type UnimplementedBizOrderServiceServer
- type UnsafeBizOrderServiceServer
Constants ¶
This section is empty.
Variables ¶
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)
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.
func NewBizOrderServiceClient ¶
func NewBizOrderServiceClient(cc grpc.ClientConnInterface) BizOrderServiceClient
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 ¶
func (m CreateOrderReplyMultiError) Error() string
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 ¶
func (e CreateOrderReplyValidationError) Cause() error
Cause function returns cause value.
func (CreateOrderReplyValidationError) Error ¶
func (e CreateOrderReplyValidationError) Error() string
Error satisfies the builtin error interface
func (CreateOrderReplyValidationError) ErrorName ¶
func (e CreateOrderReplyValidationError) ErrorName() string
ErrorName returns error name.
func (CreateOrderReplyValidationError) Field ¶
func (e CreateOrderReplyValidationError) Field() string
Field function returns field value.
func (CreateOrderReplyValidationError) Key ¶
func (e CreateOrderReplyValidationError) Key() bool
Key function returns key value.
func (CreateOrderReplyValidationError) Reason ¶
func (e CreateOrderReplyValidationError) Reason() string
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 ¶
func (m CreateOrderRequestMultiError) Error() string
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 ¶
func (e CreateOrderRequestValidationError) Cause() error
Cause function returns cause value.
func (CreateOrderRequestValidationError) Error ¶
func (e CreateOrderRequestValidationError) Error() string
Error satisfies the builtin error interface
func (CreateOrderRequestValidationError) ErrorName ¶
func (e CreateOrderRequestValidationError) ErrorName() string
ErrorName returns error name.
func (CreateOrderRequestValidationError) Field ¶
func (e CreateOrderRequestValidationError) Field() string
Field function returns field value.
func (CreateOrderRequestValidationError) Key ¶
func (e CreateOrderRequestValidationError) Key() bool
Key function returns key value.
func (CreateOrderRequestValidationError) Reason ¶
func (e CreateOrderRequestValidationError) Reason() string
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 ¶
func (m CreateOrderResponseMultiError) Error() string
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 ¶
func (e CreateOrderResponseValidationError) Cause() error
Cause function returns cause value.
func (CreateOrderResponseValidationError) Error ¶
func (e CreateOrderResponseValidationError) Error() string
Error satisfies the builtin error interface
func (CreateOrderResponseValidationError) ErrorName ¶
func (e CreateOrderResponseValidationError) ErrorName() string
ErrorName returns error name.
func (CreateOrderResponseValidationError) Field ¶
func (e CreateOrderResponseValidationError) Field() string
Field function returns field value.
func (CreateOrderResponseValidationError) Key ¶
func (e CreateOrderResponseValidationError) Key() bool
Key function returns key value.
func (CreateOrderResponseValidationError) Reason ¶
func (e CreateOrderResponseValidationError) Reason() string
Reason function returns reason value.
type UnimplementedBizOrderServiceServer ¶
type UnimplementedBizOrderServiceServer struct { }
UnimplementedBizOrderServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedBizOrderServiceServer) CreateOrder ¶
func (UnimplementedBizOrderServiceServer) CreateOrder(context.Context, *CreateOrderRequest) (*base.OperateReply, error)
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.