Documentation
¶
Overview ¶
Package crud is a generated protocol buffer package.
It is generated from these files:
pb/crud/crud_service.proto
It has these top-level messages:
Key Record UpsertResponse DeleteResponse
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterCRUDServiceServer ¶
func RegisterCRUDServiceServer(s *grpc.Server, srv CRUDServiceServer)
Types ¶
type CRUDServiceClient ¶
type CRUDServiceClient interface { Upsert(ctx context.Context, in *Record, opts ...grpc.CallOption) (*UpsertResponse, error) Read(ctx context.Context, in *Key, opts ...grpc.CallOption) (*Record, error) Delete(ctx context.Context, in *Key, opts ...grpc.CallOption) (*DeleteResponse, error) }
func NewCRUDServiceClient ¶
func NewCRUDServiceClient(cc *grpc.ClientConn) CRUDServiceClient
type CRUDServiceServer ¶
type DeleteResponse ¶
type DeleteResponse struct { }
func (*DeleteResponse) Descriptor ¶
func (*DeleteResponse) Descriptor() ([]byte, []int)
func (*DeleteResponse) ProtoMessage ¶
func (*DeleteResponse) ProtoMessage()
func (*DeleteResponse) Reset ¶
func (m *DeleteResponse) Reset()
func (*DeleteResponse) String ¶
func (m *DeleteResponse) String() string
type Key ¶
type Key struct { MovieID int32 `protobuf:"varint,1,opt,name=movieID" json:"movieID,omitempty"` UserID int32 `protobuf:"varint,2,opt,name=userID" json:"userID,omitempty"` }
func (*Key) Descriptor ¶
func (*Key) GetMovieID ¶
func (*Key) ProtoMessage ¶
func (*Key) ProtoMessage()
type Record ¶
type Record struct { MovieID int32 `protobuf:"varint,1,opt,name=movieID" json:"movieID,omitempty"` UserID int32 `protobuf:"varint,2,opt,name=userID" json:"userID,omitempty"` Rating float32 `protobuf:"fixed32,3,opt,name=rating" json:"rating,omitempty"` }
func (*Record) Descriptor ¶
func (*Record) GetMovieID ¶
func (*Record) ProtoMessage ¶
func (*Record) ProtoMessage()
type UpsertResponse ¶
type UpsertResponse struct { }
func (*UpsertResponse) Descriptor ¶
func (*UpsertResponse) Descriptor() ([]byte, []int)
func (*UpsertResponse) ProtoMessage ¶
func (*UpsertResponse) ProtoMessage()
func (*UpsertResponse) Reset ¶
func (m *UpsertResponse) Reset()
func (*UpsertResponse) String ¶
func (m *UpsertResponse) String() string
Click to show internal directories.
Click to hide internal directories.