Documentation
¶
Index ¶
- Variables
- func OrdersToNative(in []*Order) []*model.Order
- func RegisterOrderServiceServer(s *grpc.Server, srv OrderServiceServer)
- type Order
- func (*Order) Descriptor() ([]byte, []int)deprecated
- func (m *Order) FromNative(n *model.Order) *Order
- func (x *Order) GetAddedAt() *timestamp.Timestamp
- func (x *Order) GetPrice() float64
- func (x *Order) GetProductID() string
- func (x *Order) GetReferenceID() string
- func (x *Order) GetSourceURL() string
- func (x *Order) GetStatus() string
- func (x *Order) GetUniqueID() string
- func (x *Order) GetUserID() string
- func (*Order) ProtoMessage()
- func (x *Order) ProtoReflect() protoreflect.Message
- func (x *Order) Reset()
- func (x *Order) String() string
- func (m *Order) ToNative() *model.Order
- type OrderFilter
- func (*OrderFilter) Descriptor() ([]byte, []int)deprecated
- func (x *OrderFilter) GetOrderID() []string
- func (x *OrderFilter) GetRequestParams() *proto1.RequestParams
- func (x *OrderFilter) GetRequestQuery() *_struct.Struct
- func (*OrderFilter) ProtoMessage()
- func (x *OrderFilter) ProtoReflect() protoreflect.Message
- func (x *OrderFilter) Reset()
- func (x *OrderFilter) String() string
- type OrderInput
- func (*OrderInput) Descriptor() ([]byte, []int)deprecated
- func (x *OrderInput) GetOrder() *Order
- func (x *OrderInput) GetProductID() string
- func (x *OrderInput) GetReferenceID() string
- func (x *OrderInput) GetUserID() string
- func (*OrderInput) ProtoMessage()
- func (x *OrderInput) ProtoReflect() protoreflect.Message
- func (x *OrderInput) Reset()
- func (x *OrderInput) String() string
- type OrderResponse
- func (*OrderResponse) Descriptor() ([]byte, []int)deprecated
- func (x *OrderResponse) GetCount() int64
- func (x *OrderResponse) GetOrders() []*Order
- func (*OrderResponse) ProtoMessage()
- func (x *OrderResponse) ProtoReflect() protoreflect.Message
- func (x *OrderResponse) Reset()
- func (x *OrderResponse) String() string
- type OrderServiceClient
- type OrderServiceServer
- type UnimplementedOrderServiceServer
- func (*UnimplementedOrderServiceServer) AddOrder(context.Context, *OrderInput) (*OrderResponse, error)
- func (*UnimplementedOrderServiceServer) CountOrders(context.Context, *OrderFilter) (*OrderResponse, error)
- func (*UnimplementedOrderServiceServer) DeleteOrder(context.Context, *OrderFilter) (*OrderResponse, error)
- func (*UnimplementedOrderServiceServer) EditOrder(context.Context, *OrderInput) (*OrderResponse, error)
- func (*UnimplementedOrderServiceServer) GetOrders(context.Context, *OrderFilter) (*OrderResponse, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var File_orders_proto protoreflect.FileDescriptor
Functions ¶
func RegisterOrderServiceServer ¶
func RegisterOrderServiceServer(s *grpc.Server, srv OrderServiceServer)
Types ¶
type Order ¶
type Order struct {
UniqueID string `protobuf:"bytes,1,opt,name=uniqueID,proto3" json:"uniqueID,omitempty"`
UserID string `protobuf:"bytes,2,opt,name=userID,proto3" json:"userID,omitempty"`
ReferenceID string `protobuf:"bytes,3,opt,name=referenceID,proto3" json:"referenceID,omitempty"`
ProductID string `protobuf:"bytes,4,opt,name=productID,proto3" json:"productID,omitempty"`
Price float64 `protobuf:"fixed64,5,opt,name=price,proto3" json:"price,omitempty"`
Status string `protobuf:"bytes,6,opt,name=status,proto3" json:"status,omitempty"`
SourceURL string `protobuf:"bytes,7,opt,name=sourceURL,proto3" json:"sourceURL,omitempty"`
AddedAt *timestamp.Timestamp `protobuf:"bytes,8,opt,name=AddedAt,proto3" json:"AddedAt,omitempty"`
// contains filtered or unexported fields
}
func (*Order) ProtoReflect ¶
func (x *Order) ProtoReflect() protoreflect.Message
type OrderFilter ¶
type OrderFilter struct {
OrderID []string `protobuf:"bytes,1,rep,name=orderID,proto3" json:"orderID,omitempty"`
RequestQuery *_struct.Struct `protobuf:"bytes,2,opt,name=requestQuery,proto3" json:"requestQuery,omitempty"`
RequestParams *proto1.RequestParams `protobuf:"bytes,3,opt,name=requestParams,proto3" json:"requestParams,omitempty"`
// contains filtered or unexported fields
}
func (*OrderFilter) Descriptor
deprecated
func (*OrderFilter) Descriptor() ([]byte, []int)
Deprecated: Use OrderFilter.ProtoReflect.Descriptor instead.
func (*OrderFilter) GetOrderID ¶
func (x *OrderFilter) GetOrderID() []string
func (*OrderFilter) GetRequestParams ¶
func (x *OrderFilter) GetRequestParams() *proto1.RequestParams
func (*OrderFilter) GetRequestQuery ¶
func (x *OrderFilter) GetRequestQuery() *_struct.Struct
func (*OrderFilter) ProtoMessage ¶
func (*OrderFilter) ProtoMessage()
func (*OrderFilter) ProtoReflect ¶
func (x *OrderFilter) ProtoReflect() protoreflect.Message
func (*OrderFilter) Reset ¶
func (x *OrderFilter) Reset()
func (*OrderFilter) String ¶
func (x *OrderFilter) String() string
type OrderInput ¶
type OrderInput struct {
UserID string `protobuf:"bytes,2,opt,name=userID,proto3" json:"userID,omitempty"`
ReferenceID string `protobuf:"bytes,3,opt,name=referenceID,proto3" json:"referenceID,omitempty"`
ProductID string `protobuf:"bytes,4,opt,name=productID,proto3" json:"productID,omitempty"`
Order *Order `protobuf:"bytes,5,opt,name=order,proto3" json:"order,omitempty"`
// contains filtered or unexported fields
}
func (*OrderInput) Descriptor
deprecated
func (*OrderInput) Descriptor() ([]byte, []int)
Deprecated: Use OrderInput.ProtoReflect.Descriptor instead.
func (*OrderInput) GetOrder ¶
func (x *OrderInput) GetOrder() *Order
func (*OrderInput) GetProductID ¶
func (x *OrderInput) GetProductID() string
func (*OrderInput) GetReferenceID ¶
func (x *OrderInput) GetReferenceID() string
func (*OrderInput) GetUserID ¶
func (x *OrderInput) GetUserID() string
func (*OrderInput) ProtoMessage ¶
func (*OrderInput) ProtoMessage()
func (*OrderInput) ProtoReflect ¶
func (x *OrderInput) ProtoReflect() protoreflect.Message
func (*OrderInput) Reset ¶
func (x *OrderInput) Reset()
func (*OrderInput) String ¶
func (x *OrderInput) String() string
type OrderResponse ¶
type OrderResponse struct {
Orders []*Order `protobuf:"bytes,1,rep,name=orders,proto3" json:"orders,omitempty"`
Count int64 `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"`
// contains filtered or unexported fields
}
func (*OrderResponse) Descriptor
deprecated
func (*OrderResponse) Descriptor() ([]byte, []int)
Deprecated: Use OrderResponse.ProtoReflect.Descriptor instead.
func (*OrderResponse) GetCount ¶
func (x *OrderResponse) GetCount() int64
func (*OrderResponse) GetOrders ¶
func (x *OrderResponse) GetOrders() []*Order
func (*OrderResponse) ProtoMessage ¶
func (*OrderResponse) ProtoMessage()
func (*OrderResponse) ProtoReflect ¶
func (x *OrderResponse) ProtoReflect() protoreflect.Message
func (*OrderResponse) Reset ¶
func (x *OrderResponse) Reset()
func (*OrderResponse) String ¶
func (x *OrderResponse) String() string
type OrderServiceClient ¶
type OrderServiceClient interface {
GetOrders(ctx context.Context, in *OrderFilter, opts ...grpc.CallOption) (*OrderResponse, error)
CountOrders(ctx context.Context, in *OrderFilter, opts ...grpc.CallOption) (*OrderResponse, error)
AddOrder(ctx context.Context, in *OrderInput, opts ...grpc.CallOption) (*OrderResponse, error)
EditOrder(ctx context.Context, in *OrderInput, opts ...grpc.CallOption) (*OrderResponse, error)
DeleteOrder(ctx context.Context, in *OrderFilter, opts ...grpc.CallOption) (*OrderResponse, error)
}
OrderServiceClient is the client API for OrderService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewOrderServiceClient ¶
func NewOrderServiceClient(cc grpc.ClientConnInterface) OrderServiceClient
type OrderServiceServer ¶
type OrderServiceServer interface {
GetOrders(context.Context, *OrderFilter) (*OrderResponse, error)
CountOrders(context.Context, *OrderFilter) (*OrderResponse, error)
AddOrder(context.Context, *OrderInput) (*OrderResponse, error)
EditOrder(context.Context, *OrderInput) (*OrderResponse, error)
DeleteOrder(context.Context, *OrderFilter) (*OrderResponse, error)
}
OrderServiceServer is the server API for OrderService service.
type UnimplementedOrderServiceServer ¶
type UnimplementedOrderServiceServer struct {
}
UnimplementedOrderServiceServer can be embedded to have forward compatible implementations.
func (*UnimplementedOrderServiceServer) AddOrder ¶
func (*UnimplementedOrderServiceServer) AddOrder(context.Context, *OrderInput) (*OrderResponse, error)
func (*UnimplementedOrderServiceServer) CountOrders ¶
func (*UnimplementedOrderServiceServer) CountOrders(context.Context, *OrderFilter) (*OrderResponse, error)
func (*UnimplementedOrderServiceServer) DeleteOrder ¶
func (*UnimplementedOrderServiceServer) DeleteOrder(context.Context, *OrderFilter) (*OrderResponse, error)
func (*UnimplementedOrderServiceServer) EditOrder ¶
func (*UnimplementedOrderServiceServer) EditOrder(context.Context, *OrderInput) (*OrderResponse, error)
func (*UnimplementedOrderServiceServer) GetOrders ¶
func (*UnimplementedOrderServiceServer) GetOrders(context.Context, *OrderFilter) (*OrderResponse, error)
Source Files
¶
- cast.go
- orders.pb.go
Click to show internal directories.
Click to hide internal directories.