Documentation ¶
Index ¶
- Variables
- type AddItemReq
- func (*AddItemReq) Descriptor() ([]byte, []int)deprecated
- func (x *AddItemReq) FastRead(buf []byte, _type int8, number int32) (offset int, err error)
- func (x *AddItemReq) FastWrite(buf []byte) (offset int)
- func (x *AddItemReq) GetItem() *CartItem
- func (x *AddItemReq) GetUserId() uint32
- func (*AddItemReq) ProtoMessage()
- func (x *AddItemReq) ProtoReflect() protoreflect.Message
- func (x *AddItemReq) Reset()
- func (x *AddItemReq) Size() (n int)
- func (x *AddItemReq) String() string
- type AddItemResp
- func (*AddItemResp) Descriptor() ([]byte, []int)deprecated
- func (x *AddItemResp) FastRead(buf []byte, _type int8, number int32) (offset int, err error)
- func (x *AddItemResp) FastWrite(buf []byte) (offset int)
- func (*AddItemResp) ProtoMessage()
- func (x *AddItemResp) ProtoReflect() protoreflect.Message
- func (x *AddItemResp) Reset()
- func (x *AddItemResp) Size() (n int)
- func (x *AddItemResp) String() string
- type CartItem
- func (*CartItem) Descriptor() ([]byte, []int)deprecated
- func (x *CartItem) FastRead(buf []byte, _type int8, number int32) (offset int, err error)
- func (x *CartItem) FastWrite(buf []byte) (offset int)
- func (x *CartItem) GetProductId() uint32
- func (x *CartItem) GetQuantity() uint32
- func (*CartItem) ProtoMessage()
- func (x *CartItem) ProtoReflect() protoreflect.Message
- func (x *CartItem) Reset()
- func (x *CartItem) Size() (n int)
- func (x *CartItem) String() string
- type CartService
- type EmptyCartReq
- func (*EmptyCartReq) Descriptor() ([]byte, []int)deprecated
- func (x *EmptyCartReq) FastRead(buf []byte, _type int8, number int32) (offset int, err error)
- func (x *EmptyCartReq) FastWrite(buf []byte) (offset int)
- func (x *EmptyCartReq) GetUserId() uint32
- func (*EmptyCartReq) ProtoMessage()
- func (x *EmptyCartReq) ProtoReflect() protoreflect.Message
- func (x *EmptyCartReq) Reset()
- func (x *EmptyCartReq) Size() (n int)
- func (x *EmptyCartReq) String() string
- type EmptyCartResp
- func (*EmptyCartResp) Descriptor() ([]byte, []int)deprecated
- func (x *EmptyCartResp) FastRead(buf []byte, _type int8, number int32) (offset int, err error)
- func (x *EmptyCartResp) FastWrite(buf []byte) (offset int)
- func (*EmptyCartResp) ProtoMessage()
- func (x *EmptyCartResp) ProtoReflect() protoreflect.Message
- func (x *EmptyCartResp) Reset()
- func (x *EmptyCartResp) Size() (n int)
- func (x *EmptyCartResp) String() string
- type GetCartReq
- func (*GetCartReq) Descriptor() ([]byte, []int)deprecated
- func (x *GetCartReq) FastRead(buf []byte, _type int8, number int32) (offset int, err error)
- func (x *GetCartReq) FastWrite(buf []byte) (offset int)
- func (x *GetCartReq) GetUserId() uint32
- func (*GetCartReq) ProtoMessage()
- func (x *GetCartReq) ProtoReflect() protoreflect.Message
- func (x *GetCartReq) Reset()
- func (x *GetCartReq) Size() (n int)
- func (x *GetCartReq) String() string
- type GetCartResp
- func (*GetCartResp) Descriptor() ([]byte, []int)deprecated
- func (x *GetCartResp) FastRead(buf []byte, _type int8, number int32) (offset int, err error)
- func (x *GetCartResp) FastWrite(buf []byte) (offset int)
- func (x *GetCartResp) GetItems() []*CartItem
- func (*GetCartResp) ProtoMessage()
- func (x *GetCartResp) ProtoReflect() protoreflect.Message
- func (x *GetCartResp) Reset()
- func (x *GetCartResp) Size() (n int)
- func (x *GetCartResp) String() string
Constants ¶
This section is empty.
Variables ¶
View Source
var File_rpc_cart_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type AddItemReq ¶
type AddItemReq struct { UserId uint32 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` Item *CartItem `protobuf:"bytes,2,opt,name=item,proto3" json:"item,omitempty"` // contains filtered or unexported fields }
func (*AddItemReq) Descriptor
deprecated
func (*AddItemReq) Descriptor() ([]byte, []int)
Deprecated: Use AddItemReq.ProtoReflect.Descriptor instead.
func (*AddItemReq) FastWrite ¶
func (x *AddItemReq) FastWrite(buf []byte) (offset int)
func (*AddItemReq) GetItem ¶
func (x *AddItemReq) GetItem() *CartItem
func (*AddItemReq) GetUserId ¶
func (x *AddItemReq) GetUserId() uint32
func (*AddItemReq) ProtoMessage ¶
func (*AddItemReq) ProtoMessage()
func (*AddItemReq) ProtoReflect ¶
func (x *AddItemReq) ProtoReflect() protoreflect.Message
func (*AddItemReq) Reset ¶
func (x *AddItemReq) Reset()
func (*AddItemReq) Size ¶
func (x *AddItemReq) Size() (n int)
func (*AddItemReq) String ¶
func (x *AddItemReq) String() string
type AddItemResp ¶
type AddItemResp struct {
// contains filtered or unexported fields
}
func (*AddItemResp) Descriptor
deprecated
func (*AddItemResp) Descriptor() ([]byte, []int)
Deprecated: Use AddItemResp.ProtoReflect.Descriptor instead.
func (*AddItemResp) FastWrite ¶
func (x *AddItemResp) FastWrite(buf []byte) (offset int)
func (*AddItemResp) ProtoMessage ¶
func (*AddItemResp) ProtoMessage()
func (*AddItemResp) ProtoReflect ¶
func (x *AddItemResp) ProtoReflect() protoreflect.Message
func (*AddItemResp) Reset ¶
func (x *AddItemResp) Reset()
func (*AddItemResp) Size ¶
func (x *AddItemResp) Size() (n int)
func (*AddItemResp) String ¶
func (x *AddItemResp) String() string
type CartItem ¶
type CartItem struct { ProductId uint32 `protobuf:"varint,1,opt,name=product_id,json=productId,proto3" json:"product_id,omitempty"` Quantity uint32 `protobuf:"varint,2,opt,name=quantity,proto3" json:"quantity,omitempty"` // contains filtered or unexported fields }
func (*CartItem) Descriptor
deprecated
func (*CartItem) GetProductId ¶
func (*CartItem) GetQuantity ¶
func (*CartItem) ProtoMessage ¶
func (*CartItem) ProtoMessage()
func (*CartItem) ProtoReflect ¶
func (x *CartItem) ProtoReflect() protoreflect.Message
type CartService ¶
type CartService interface { AddItem(ctx context.Context, req *AddItemReq) (res *AddItemResp, err error) GetCart(ctx context.Context, req *GetCartReq) (res *GetCartResp, err error) EmptyCart(ctx context.Context, req *EmptyCartReq) (res *EmptyCartResp, err error) }
type EmptyCartReq ¶
type EmptyCartReq struct { UserId uint32 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` // contains filtered or unexported fields }
func (*EmptyCartReq) Descriptor
deprecated
func (*EmptyCartReq) Descriptor() ([]byte, []int)
Deprecated: Use EmptyCartReq.ProtoReflect.Descriptor instead.
func (*EmptyCartReq) FastWrite ¶
func (x *EmptyCartReq) FastWrite(buf []byte) (offset int)
func (*EmptyCartReq) GetUserId ¶
func (x *EmptyCartReq) GetUserId() uint32
func (*EmptyCartReq) ProtoMessage ¶
func (*EmptyCartReq) ProtoMessage()
func (*EmptyCartReq) ProtoReflect ¶
func (x *EmptyCartReq) ProtoReflect() protoreflect.Message
func (*EmptyCartReq) Reset ¶
func (x *EmptyCartReq) Reset()
func (*EmptyCartReq) Size ¶
func (x *EmptyCartReq) Size() (n int)
func (*EmptyCartReq) String ¶
func (x *EmptyCartReq) String() string
type EmptyCartResp ¶
type EmptyCartResp struct {
// contains filtered or unexported fields
}
func (*EmptyCartResp) Descriptor
deprecated
func (*EmptyCartResp) Descriptor() ([]byte, []int)
Deprecated: Use EmptyCartResp.ProtoReflect.Descriptor instead.
func (*EmptyCartResp) FastWrite ¶
func (x *EmptyCartResp) FastWrite(buf []byte) (offset int)
func (*EmptyCartResp) ProtoMessage ¶
func (*EmptyCartResp) ProtoMessage()
func (*EmptyCartResp) ProtoReflect ¶
func (x *EmptyCartResp) ProtoReflect() protoreflect.Message
func (*EmptyCartResp) Reset ¶
func (x *EmptyCartResp) Reset()
func (*EmptyCartResp) Size ¶
func (x *EmptyCartResp) Size() (n int)
func (*EmptyCartResp) String ¶
func (x *EmptyCartResp) String() string
type GetCartReq ¶
type GetCartReq struct { UserId uint32 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` // contains filtered or unexported fields }
func (*GetCartReq) Descriptor
deprecated
func (*GetCartReq) Descriptor() ([]byte, []int)
Deprecated: Use GetCartReq.ProtoReflect.Descriptor instead.
func (*GetCartReq) FastWrite ¶
func (x *GetCartReq) FastWrite(buf []byte) (offset int)
func (*GetCartReq) GetUserId ¶
func (x *GetCartReq) GetUserId() uint32
func (*GetCartReq) ProtoMessage ¶
func (*GetCartReq) ProtoMessage()
func (*GetCartReq) ProtoReflect ¶
func (x *GetCartReq) ProtoReflect() protoreflect.Message
func (*GetCartReq) Reset ¶
func (x *GetCartReq) Reset()
func (*GetCartReq) Size ¶
func (x *GetCartReq) Size() (n int)
func (*GetCartReq) String ¶
func (x *GetCartReq) String() string
type GetCartResp ¶
type GetCartResp struct { Items []*CartItem `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"` // contains filtered or unexported fields }
func (*GetCartResp) Descriptor
deprecated
func (*GetCartResp) Descriptor() ([]byte, []int)
Deprecated: Use GetCartResp.ProtoReflect.Descriptor instead.
func (*GetCartResp) FastWrite ¶
func (x *GetCartResp) FastWrite(buf []byte) (offset int)
func (*GetCartResp) GetItems ¶
func (x *GetCartResp) GetItems() []*CartItem
func (*GetCartResp) ProtoMessage ¶
func (*GetCartResp) ProtoMessage()
func (*GetCartResp) ProtoReflect ¶
func (x *GetCartResp) ProtoReflect() protoreflect.Message
func (*GetCartResp) Reset ¶
func (x *GetCartResp) Reset()
func (*GetCartResp) Size ¶
func (x *GetCartResp) Size() (n int)
func (*GetCartResp) String ¶
func (x *GetCartResp) String() string
Click to show internal directories.
Click to hide internal directories.