Documentation ¶
Index ¶
- Variables
- func RegisterPriceServer(s grpc.ServiceRegistrar, srv PriceServer)
- type FetchReply
- type FetchRequest
- type ListReply
- type ListReply_Price
- func (*ListReply_Price) Descriptor() ([]byte, []int)deprecated
- func (x *ListReply_Price) GetChanges() int64
- func (x *ListReply_Price) GetName() string
- func (x *ListReply_Price) GetPrice() float64
- func (x *ListReply_Price) GetUpdatedAt() *timestamppb.Timestamp
- func (*ListReply_Price) ProtoMessage()
- func (x *ListReply_Price) ProtoReflect() protoreflect.Message
- func (x *ListReply_Price) Reset()
- func (x *ListReply_Price) String() string
- type ListRequest
- func (*ListRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ListRequest) GetLimit() int64
- func (x *ListRequest) GetOrderBy() string
- func (x *ListRequest) GetOrderType() int32
- func (x *ListRequest) GetSkip() int64
- func (*ListRequest) ProtoMessage()
- func (x *ListRequest) ProtoReflect() protoreflect.Message
- func (x *ListRequest) Reset()
- func (x *ListRequest) String() string
- type PriceClient
- type PriceServer
- type UnimplementedPriceServer
- type UnsafePriceServer
Constants ¶
This section is empty.
Variables ¶
var File_internal_proto_price_proto protoreflect.FileDescriptor
var Price_ServiceDesc = grpc.ServiceDesc{ ServiceName: "proto.Price", HandlerType: (*PriceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Fetch", Handler: _Price_Fetch_Handler, }, { MethodName: "List", Handler: _Price_List_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "internal/proto/price.proto", }
Price_ServiceDesc is the grpc.ServiceDesc for Price service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterPriceServer ¶
func RegisterPriceServer(s grpc.ServiceRegistrar, srv PriceServer)
Types ¶
type FetchReply ¶
type FetchReply struct {
// contains filtered or unexported fields
}
func (*FetchReply) Descriptor
deprecated
func (*FetchReply) Descriptor() ([]byte, []int)
Deprecated: Use FetchReply.ProtoReflect.Descriptor instead.
func (*FetchReply) ProtoMessage ¶
func (*FetchReply) ProtoMessage()
func (*FetchReply) ProtoReflect ¶
func (x *FetchReply) ProtoReflect() protoreflect.Message
func (*FetchReply) Reset ¶
func (x *FetchReply) Reset()
func (*FetchReply) String ¶
func (x *FetchReply) String() string
type FetchRequest ¶
type FetchRequest struct { Url string `protobuf:"bytes,1,opt,name=url,proto3" json:"url,omitempty"` // contains filtered or unexported fields }
func (*FetchRequest) Descriptor
deprecated
func (*FetchRequest) Descriptor() ([]byte, []int)
Deprecated: Use FetchRequest.ProtoReflect.Descriptor instead.
func (*FetchRequest) GetUrl ¶
func (x *FetchRequest) GetUrl() string
func (*FetchRequest) ProtoMessage ¶
func (*FetchRequest) ProtoMessage()
func (*FetchRequest) ProtoReflect ¶
func (x *FetchRequest) ProtoReflect() protoreflect.Message
func (*FetchRequest) Reset ¶
func (x *FetchRequest) Reset()
func (*FetchRequest) String ¶
func (x *FetchRequest) String() string
type ListReply ¶
type ListReply struct { Results []*ListReply_Price `protobuf:"bytes,3,rep,name=results,proto3" json:"results,omitempty"` // contains filtered or unexported fields }
func (*ListReply) Descriptor
deprecated
func (*ListReply) GetResults ¶
func (x *ListReply) GetResults() []*ListReply_Price
func (*ListReply) ProtoMessage ¶
func (*ListReply) ProtoMessage()
func (*ListReply) ProtoReflect ¶
func (x *ListReply) ProtoReflect() protoreflect.Message
type ListReply_Price ¶
type ListReply_Price struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Price float64 `protobuf:"fixed64,2,opt,name=price,proto3" json:"price,omitempty"` Changes int64 `protobuf:"varint,3,opt,name=changes,proto3" json:"changes,omitempty"` UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"` // contains filtered or unexported fields }
func (*ListReply_Price) Descriptor
deprecated
func (*ListReply_Price) Descriptor() ([]byte, []int)
Deprecated: Use ListReply_Price.ProtoReflect.Descriptor instead.
func (*ListReply_Price) GetChanges ¶
func (x *ListReply_Price) GetChanges() int64
func (*ListReply_Price) GetName ¶
func (x *ListReply_Price) GetName() string
func (*ListReply_Price) GetPrice ¶
func (x *ListReply_Price) GetPrice() float64
func (*ListReply_Price) GetUpdatedAt ¶
func (x *ListReply_Price) GetUpdatedAt() *timestamppb.Timestamp
func (*ListReply_Price) ProtoMessage ¶
func (*ListReply_Price) ProtoMessage()
func (*ListReply_Price) ProtoReflect ¶
func (x *ListReply_Price) ProtoReflect() protoreflect.Message
func (*ListReply_Price) Reset ¶
func (x *ListReply_Price) Reset()
func (*ListReply_Price) String ¶
func (x *ListReply_Price) String() string
type ListRequest ¶
type ListRequest struct { Skip int64 `protobuf:"varint,2,opt,name=skip,proto3" json:"skip,omitempty"` Limit int64 `protobuf:"varint,3,opt,name=limit,proto3" json:"limit,omitempty"` OrderBy string `protobuf:"bytes,4,opt,name=order_by,json=orderBy,proto3" json:"order_by,omitempty"` OrderType int32 `protobuf:"varint,5,opt,name=order_type,json=orderType,proto3" json:"order_type,omitempty"` // contains filtered or unexported fields }
func (*ListRequest) Descriptor
deprecated
func (*ListRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListRequest.ProtoReflect.Descriptor instead.
func (*ListRequest) GetLimit ¶
func (x *ListRequest) GetLimit() int64
func (*ListRequest) GetOrderBy ¶
func (x *ListRequest) GetOrderBy() string
func (*ListRequest) GetOrderType ¶
func (x *ListRequest) GetOrderType() int32
func (*ListRequest) GetSkip ¶
func (x *ListRequest) GetSkip() int64
func (*ListRequest) ProtoMessage ¶
func (*ListRequest) ProtoMessage()
func (*ListRequest) ProtoReflect ¶
func (x *ListRequest) ProtoReflect() protoreflect.Message
func (*ListRequest) Reset ¶
func (x *ListRequest) Reset()
func (*ListRequest) String ¶
func (x *ListRequest) String() string
type PriceClient ¶
type PriceClient interface { Fetch(ctx context.Context, in *FetchRequest, opts ...grpc.CallOption) (*FetchReply, error) List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListReply, error) }
PriceClient is the client API for Price 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 NewPriceClient ¶
func NewPriceClient(cc grpc.ClientConnInterface) PriceClient
type PriceServer ¶
type PriceServer interface { Fetch(context.Context, *FetchRequest) (*FetchReply, error) List(context.Context, *ListRequest) (*ListReply, error) // contains filtered or unexported methods }
PriceServer is the server API for Price service. All implementations must embed UnimplementedPriceServer for forward compatibility
type UnimplementedPriceServer ¶
type UnimplementedPriceServer struct { }
UnimplementedPriceServer must be embedded to have forward compatible implementations.
func (UnimplementedPriceServer) Fetch ¶
func (UnimplementedPriceServer) Fetch(context.Context, *FetchRequest) (*FetchReply, error)
func (UnimplementedPriceServer) List ¶
func (UnimplementedPriceServer) List(context.Context, *ListRequest) (*ListReply, error)
type UnsafePriceServer ¶
type UnsafePriceServer interface {
// contains filtered or unexported methods
}
UnsafePriceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PriceServer will result in compilation errors.