Documentation ¶
Index ¶
- Constants
- Variables
- func ErrorRatingNotFound(format string, args ...interface{}) *errors.Error
- func IsRatingNotFound(err error) bool
- func RegisterRatingServiceHTTPServer(s *http.Server, srv RatingServiceHTTPServer)
- func RegisterRatingServiceServer(s grpc.ServiceRegistrar, srv RatingServiceServer)
- type CreateRatingRequest
- func (*CreateRatingRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateRatingRequest) GetRating() *Rating
- func (*CreateRatingRequest) ProtoMessage()
- func (x *CreateRatingRequest) ProtoReflect() protoreflect.Message
- func (x *CreateRatingRequest) Reset()
- func (x *CreateRatingRequest) String() string
- func (m *CreateRatingRequest) Validate() error
- func (m *CreateRatingRequest) ValidateAll() error
- type CreateRatingRequestMultiError
- type CreateRatingRequestValidationError
- func (e CreateRatingRequestValidationError) Cause() error
- func (e CreateRatingRequestValidationError) Error() string
- func (e CreateRatingRequestValidationError) ErrorName() string
- func (e CreateRatingRequestValidationError) Field() string
- func (e CreateRatingRequestValidationError) Key() bool
- func (e CreateRatingRequestValidationError) Reason() string
- type CreateRatingResponse
- func (*CreateRatingResponse) Descriptor() ([]byte, []int)deprecated
- func (*CreateRatingResponse) ProtoMessage()
- func (x *CreateRatingResponse) ProtoReflect() protoreflect.Message
- func (x *CreateRatingResponse) Reset()
- func (x *CreateRatingResponse) String() string
- func (m *CreateRatingResponse) Validate() error
- func (m *CreateRatingResponse) ValidateAll() error
- type CreateRatingResponseMultiError
- type CreateRatingResponseValidationError
- func (e CreateRatingResponseValidationError) Cause() error
- func (e CreateRatingResponseValidationError) Error() string
- func (e CreateRatingResponseValidationError) ErrorName() string
- func (e CreateRatingResponseValidationError) Field() string
- func (e CreateRatingResponseValidationError) Key() bool
- func (e CreateRatingResponseValidationError) Reason() string
- type ErrorReason
- func (ErrorReason) Descriptor() protoreflect.EnumDescriptor
- func (x ErrorReason) Enum() *ErrorReason
- func (ErrorReason) EnumDescriptor() ([]byte, []int)deprecated
- func (x ErrorReason) Number() protoreflect.EnumNumber
- func (x ErrorReason) String() string
- func (ErrorReason) Type() protoreflect.EnumType
- type GetAggregatedRatingRequest
- func (*GetAggregatedRatingRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetAggregatedRatingRequest) GetRecordId() uint64
- func (x *GetAggregatedRatingRequest) GetRecordType() RECORDTYPE
- func (*GetAggregatedRatingRequest) ProtoMessage()
- func (x *GetAggregatedRatingRequest) ProtoReflect() protoreflect.Message
- func (x *GetAggregatedRatingRequest) Reset()
- func (x *GetAggregatedRatingRequest) String() string
- func (m *GetAggregatedRatingRequest) Validate() error
- func (m *GetAggregatedRatingRequest) ValidateAll() error
- type GetAggregatedRatingRequestMultiError
- type GetAggregatedRatingRequestValidationError
- func (e GetAggregatedRatingRequestValidationError) Cause() error
- func (e GetAggregatedRatingRequestValidationError) Error() string
- func (e GetAggregatedRatingRequestValidationError) ErrorName() string
- func (e GetAggregatedRatingRequestValidationError) Field() string
- func (e GetAggregatedRatingRequestValidationError) Key() bool
- func (e GetAggregatedRatingRequestValidationError) Reason() string
- type GetAggregatedRatingResponse
- func (*GetAggregatedRatingResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetAggregatedRatingResponse) GetAvgRating() float64
- func (*GetAggregatedRatingResponse) ProtoMessage()
- func (x *GetAggregatedRatingResponse) ProtoReflect() protoreflect.Message
- func (x *GetAggregatedRatingResponse) Reset()
- func (x *GetAggregatedRatingResponse) String() string
- func (m *GetAggregatedRatingResponse) Validate() error
- func (m *GetAggregatedRatingResponse) ValidateAll() error
- type GetAggregatedRatingResponseMultiError
- type GetAggregatedRatingResponseValidationError
- func (e GetAggregatedRatingResponseValidationError) Cause() error
- func (e GetAggregatedRatingResponseValidationError) Error() string
- func (e GetAggregatedRatingResponseValidationError) ErrorName() string
- func (e GetAggregatedRatingResponseValidationError) Field() string
- func (e GetAggregatedRatingResponseValidationError) Key() bool
- func (e GetAggregatedRatingResponseValidationError) Reason() string
- type PushMsg
- func (*PushMsg) Descriptor() ([]byte, []int)deprecated
- func (x *PushMsg) GetKey() string
- func (x *PushMsg) GetMsg() []byte
- func (x *PushMsg) GetType() PushMsg_Type
- func (*PushMsg) ProtoMessage()
- func (x *PushMsg) ProtoReflect() protoreflect.Message
- func (x *PushMsg) Reset()
- func (x *PushMsg) String() string
- func (m *PushMsg) Validate() error
- func (m *PushMsg) ValidateAll() error
- type PushMsgMultiError
- type PushMsgValidationError
- type PushMsg_Type
- func (PushMsg_Type) Descriptor() protoreflect.EnumDescriptor
- func (x PushMsg_Type) Enum() *PushMsg_Type
- func (PushMsg_Type) EnumDescriptor() ([]byte, []int)deprecated
- func (x PushMsg_Type) Number() protoreflect.EnumNumber
- func (x PushMsg_Type) String() string
- func (PushMsg_Type) Type() protoreflect.EnumType
- type RECORDTYPE
- type Rating
- func (*Rating) Descriptor() ([]byte, []int)deprecated
- func (x *Rating) GetRatingValue() uint32
- func (x *Rating) GetRecordId() uint64
- func (x *Rating) GetRecordType() RECORDTYPE
- func (x *Rating) GetUserId() uint64
- func (*Rating) ProtoMessage()
- func (x *Rating) ProtoReflect() protoreflect.Message
- func (x *Rating) Reset()
- func (x *Rating) String() string
- func (m *Rating) Validate() error
- func (m *Rating) ValidateAll() error
- type RatingMultiError
- type RatingServiceClient
- type RatingServiceHTTPClient
- type RatingServiceHTTPClientImpl
- func (c *RatingServiceHTTPClientImpl) CreateRating(ctx context.Context, in *CreateRatingRequest, opts ...http.CallOption) (*CreateRatingResponse, error)
- func (c *RatingServiceHTTPClientImpl) GetAggregatedRating(ctx context.Context, in *GetAggregatedRatingRequest, opts ...http.CallOption) (*GetAggregatedRatingResponse, error)
- type RatingServiceHTTPServer
- type RatingServiceServer
- type RatingValidationError
- type UnimplementedRatingServiceServer
- type UnsafeRatingServiceServer
Constants ¶
const ( RatingService_GetAggregatedRating_FullMethodName = "/rating.service.v1.RatingService/GetAggregatedRating" RatingService_CreateRating_FullMethodName = "/rating.service.v1.RatingService/CreateRating" )
const OperationRatingServiceCreateRating = "/rating.service.v1.RatingService/CreateRating"
const OperationRatingServiceGetAggregatedRating = "/rating.service.v1.RatingService/GetAggregatedRating"
Variables ¶
var ( RECORDTYPE_name = map[int32]string{ 0: "RECORDTYPE_UNSPECIFIED", 1: "RECORDTYPE_MOVIE", } RECORDTYPE_value = map[string]int32{ "RECORDTYPE_UNSPECIFIED": 0, "RECORDTYPE_MOVIE": 1, } )
Enum value maps for RECORDTYPE.
var ( PushMsg_Type_name = map[int32]string{ 0: "TYPE_UNSPECIFIED", 1: "TYPE_METADATA_CREATE", 2: "TYPE_METADATA_DELETE", } PushMsg_Type_value = map[string]int32{ "TYPE_UNSPECIFIED": 0, "TYPE_METADATA_CREATE": 1, "TYPE_METADATA_DELETE": 2, } )
Enum value maps for PushMsg_Type.
var ( ErrorReason_name = map[int32]string{ 0: "RATING_NOT_FOUND", } ErrorReason_value = map[string]int32{ "RATING_NOT_FOUND": 0, } )
Enum value maps for ErrorReason.
var File_rating_service_v1_rating_error_proto protoreflect.FileDescriptor
var File_rating_service_v1_rating_proto protoreflect.FileDescriptor
var RatingService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "rating.service.v1.RatingService", HandlerType: (*RatingServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetAggregatedRating", Handler: _RatingService_GetAggregatedRating_Handler, }, { MethodName: "CreateRating", Handler: _RatingService_CreateRating_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "rating/service/v1/rating.proto", }
RatingService_ServiceDesc is the grpc.ServiceDesc for RatingService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func ErrorRatingNotFound ¶
func IsRatingNotFound ¶
func RegisterRatingServiceHTTPServer ¶
func RegisterRatingServiceHTTPServer(s *http.Server, srv RatingServiceHTTPServer)
func RegisterRatingServiceServer ¶
func RegisterRatingServiceServer(s grpc.ServiceRegistrar, srv RatingServiceServer)
Types ¶
type CreateRatingRequest ¶
type CreateRatingRequest struct { Rating *Rating `protobuf:"bytes,1,opt,name=rating,proto3" json:"rating,omitempty"` // contains filtered or unexported fields }
func (*CreateRatingRequest) Descriptor
deprecated
func (*CreateRatingRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateRatingRequest.ProtoReflect.Descriptor instead.
func (*CreateRatingRequest) GetRating ¶
func (x *CreateRatingRequest) GetRating() *Rating
func (*CreateRatingRequest) ProtoMessage ¶
func (*CreateRatingRequest) ProtoMessage()
func (*CreateRatingRequest) ProtoReflect ¶
func (x *CreateRatingRequest) ProtoReflect() protoreflect.Message
func (*CreateRatingRequest) Reset ¶
func (x *CreateRatingRequest) Reset()
func (*CreateRatingRequest) String ¶
func (x *CreateRatingRequest) String() string
func (*CreateRatingRequest) Validate ¶
func (m *CreateRatingRequest) Validate() error
Validate checks the field values on CreateRatingRequest 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 (*CreateRatingRequest) ValidateAll ¶
func (m *CreateRatingRequest) ValidateAll() error
ValidateAll checks the field values on CreateRatingRequest 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 CreateRatingRequestMultiError, or nil if none found.
type CreateRatingRequestMultiError ¶
type CreateRatingRequestMultiError []error
CreateRatingRequestMultiError is an error wrapping multiple validation errors returned by CreateRatingRequest.ValidateAll() if the designated constraints aren't met.
func (CreateRatingRequestMultiError) AllErrors ¶
func (m CreateRatingRequestMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (CreateRatingRequestMultiError) Error ¶
func (m CreateRatingRequestMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type CreateRatingRequestValidationError ¶
type CreateRatingRequestValidationError struct {
// contains filtered or unexported fields
}
CreateRatingRequestValidationError is the validation error returned by CreateRatingRequest.Validate if the designated constraints aren't met.
func (CreateRatingRequestValidationError) Cause ¶
func (e CreateRatingRequestValidationError) Cause() error
Cause function returns cause value.
func (CreateRatingRequestValidationError) Error ¶
func (e CreateRatingRequestValidationError) Error() string
Error satisfies the builtin error interface
func (CreateRatingRequestValidationError) ErrorName ¶
func (e CreateRatingRequestValidationError) ErrorName() string
ErrorName returns error name.
func (CreateRatingRequestValidationError) Field ¶
func (e CreateRatingRequestValidationError) Field() string
Field function returns field value.
func (CreateRatingRequestValidationError) Key ¶
func (e CreateRatingRequestValidationError) Key() bool
Key function returns key value.
func (CreateRatingRequestValidationError) Reason ¶
func (e CreateRatingRequestValidationError) Reason() string
Reason function returns reason value.
type CreateRatingResponse ¶
type CreateRatingResponse struct {
// contains filtered or unexported fields
}
func (*CreateRatingResponse) Descriptor
deprecated
func (*CreateRatingResponse) Descriptor() ([]byte, []int)
Deprecated: Use CreateRatingResponse.ProtoReflect.Descriptor instead.
func (*CreateRatingResponse) ProtoMessage ¶
func (*CreateRatingResponse) ProtoMessage()
func (*CreateRatingResponse) ProtoReflect ¶
func (x *CreateRatingResponse) ProtoReflect() protoreflect.Message
func (*CreateRatingResponse) Reset ¶
func (x *CreateRatingResponse) Reset()
func (*CreateRatingResponse) String ¶
func (x *CreateRatingResponse) String() string
func (*CreateRatingResponse) Validate ¶
func (m *CreateRatingResponse) Validate() error
Validate checks the field values on CreateRatingResponse 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 (*CreateRatingResponse) ValidateAll ¶
func (m *CreateRatingResponse) ValidateAll() error
ValidateAll checks the field values on CreateRatingResponse 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 CreateRatingResponseMultiError, or nil if none found.
type CreateRatingResponseMultiError ¶
type CreateRatingResponseMultiError []error
CreateRatingResponseMultiError is an error wrapping multiple validation errors returned by CreateRatingResponse.ValidateAll() if the designated constraints aren't met.
func (CreateRatingResponseMultiError) AllErrors ¶
func (m CreateRatingResponseMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (CreateRatingResponseMultiError) Error ¶
func (m CreateRatingResponseMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type CreateRatingResponseValidationError ¶
type CreateRatingResponseValidationError struct {
// contains filtered or unexported fields
}
CreateRatingResponseValidationError is the validation error returned by CreateRatingResponse.Validate if the designated constraints aren't met.
func (CreateRatingResponseValidationError) Cause ¶
func (e CreateRatingResponseValidationError) Cause() error
Cause function returns cause value.
func (CreateRatingResponseValidationError) Error ¶
func (e CreateRatingResponseValidationError) Error() string
Error satisfies the builtin error interface
func (CreateRatingResponseValidationError) ErrorName ¶
func (e CreateRatingResponseValidationError) ErrorName() string
ErrorName returns error name.
func (CreateRatingResponseValidationError) Field ¶
func (e CreateRatingResponseValidationError) Field() string
Field function returns field value.
func (CreateRatingResponseValidationError) Key ¶
func (e CreateRatingResponseValidationError) Key() bool
Key function returns key value.
func (CreateRatingResponseValidationError) Reason ¶
func (e CreateRatingResponseValidationError) Reason() string
Reason function returns reason value.
type ErrorReason ¶
type ErrorReason int32
const (
ErrorReason_RATING_NOT_FOUND ErrorReason = 0
)
func (ErrorReason) Descriptor ¶
func (ErrorReason) Descriptor() protoreflect.EnumDescriptor
func (ErrorReason) Enum ¶
func (x ErrorReason) Enum() *ErrorReason
func (ErrorReason) EnumDescriptor
deprecated
func (ErrorReason) EnumDescriptor() ([]byte, []int)
Deprecated: Use ErrorReason.Descriptor instead.
func (ErrorReason) Number ¶
func (x ErrorReason) Number() protoreflect.EnumNumber
func (ErrorReason) String ¶
func (x ErrorReason) String() string
func (ErrorReason) Type ¶
func (ErrorReason) Type() protoreflect.EnumType
type GetAggregatedRatingRequest ¶
type GetAggregatedRatingRequest struct { RecordType RECORDTYPE `` /* 126-byte string literal not displayed */ RecordId uint64 `protobuf:"varint,2,opt,name=record_id,json=recordId,proto3" json:"record_id,omitempty"` // contains filtered or unexported fields }
func (*GetAggregatedRatingRequest) Descriptor
deprecated
func (*GetAggregatedRatingRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetAggregatedRatingRequest.ProtoReflect.Descriptor instead.
func (*GetAggregatedRatingRequest) GetRecordId ¶
func (x *GetAggregatedRatingRequest) GetRecordId() uint64
func (*GetAggregatedRatingRequest) GetRecordType ¶
func (x *GetAggregatedRatingRequest) GetRecordType() RECORDTYPE
func (*GetAggregatedRatingRequest) ProtoMessage ¶
func (*GetAggregatedRatingRequest) ProtoMessage()
func (*GetAggregatedRatingRequest) ProtoReflect ¶
func (x *GetAggregatedRatingRequest) ProtoReflect() protoreflect.Message
func (*GetAggregatedRatingRequest) Reset ¶
func (x *GetAggregatedRatingRequest) Reset()
func (*GetAggregatedRatingRequest) String ¶
func (x *GetAggregatedRatingRequest) String() string
func (*GetAggregatedRatingRequest) Validate ¶
func (m *GetAggregatedRatingRequest) Validate() error
Validate checks the field values on GetAggregatedRatingRequest 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 (*GetAggregatedRatingRequest) ValidateAll ¶
func (m *GetAggregatedRatingRequest) ValidateAll() error
ValidateAll checks the field values on GetAggregatedRatingRequest 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 GetAggregatedRatingRequestMultiError, or nil if none found.
type GetAggregatedRatingRequestMultiError ¶
type GetAggregatedRatingRequestMultiError []error
GetAggregatedRatingRequestMultiError is an error wrapping multiple validation errors returned by GetAggregatedRatingRequest.ValidateAll() if the designated constraints aren't met.
func (GetAggregatedRatingRequestMultiError) AllErrors ¶
func (m GetAggregatedRatingRequestMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (GetAggregatedRatingRequestMultiError) Error ¶
func (m GetAggregatedRatingRequestMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type GetAggregatedRatingRequestValidationError ¶
type GetAggregatedRatingRequestValidationError struct {
// contains filtered or unexported fields
}
GetAggregatedRatingRequestValidationError is the validation error returned by GetAggregatedRatingRequest.Validate if the designated constraints aren't met.
func (GetAggregatedRatingRequestValidationError) Cause ¶
func (e GetAggregatedRatingRequestValidationError) Cause() error
Cause function returns cause value.
func (GetAggregatedRatingRequestValidationError) Error ¶
func (e GetAggregatedRatingRequestValidationError) Error() string
Error satisfies the builtin error interface
func (GetAggregatedRatingRequestValidationError) ErrorName ¶
func (e GetAggregatedRatingRequestValidationError) ErrorName() string
ErrorName returns error name.
func (GetAggregatedRatingRequestValidationError) Field ¶
func (e GetAggregatedRatingRequestValidationError) Field() string
Field function returns field value.
func (GetAggregatedRatingRequestValidationError) Key ¶
func (e GetAggregatedRatingRequestValidationError) Key() bool
Key function returns key value.
func (GetAggregatedRatingRequestValidationError) Reason ¶
func (e GetAggregatedRatingRequestValidationError) Reason() string
Reason function returns reason value.
type GetAggregatedRatingResponse ¶
type GetAggregatedRatingResponse struct { AvgRating float64 `protobuf:"fixed64,1,opt,name=avg_rating,json=avgRating,proto3" json:"avg_rating,omitempty"` // contains filtered or unexported fields }
func (*GetAggregatedRatingResponse) Descriptor
deprecated
func (*GetAggregatedRatingResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetAggregatedRatingResponse.ProtoReflect.Descriptor instead.
func (*GetAggregatedRatingResponse) GetAvgRating ¶
func (x *GetAggregatedRatingResponse) GetAvgRating() float64
func (*GetAggregatedRatingResponse) ProtoMessage ¶
func (*GetAggregatedRatingResponse) ProtoMessage()
func (*GetAggregatedRatingResponse) ProtoReflect ¶
func (x *GetAggregatedRatingResponse) ProtoReflect() protoreflect.Message
func (*GetAggregatedRatingResponse) Reset ¶
func (x *GetAggregatedRatingResponse) Reset()
func (*GetAggregatedRatingResponse) String ¶
func (x *GetAggregatedRatingResponse) String() string
func (*GetAggregatedRatingResponse) Validate ¶
func (m *GetAggregatedRatingResponse) Validate() error
Validate checks the field values on GetAggregatedRatingResponse 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 (*GetAggregatedRatingResponse) ValidateAll ¶
func (m *GetAggregatedRatingResponse) ValidateAll() error
ValidateAll checks the field values on GetAggregatedRatingResponse 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 GetAggregatedRatingResponseMultiError, or nil if none found.
type GetAggregatedRatingResponseMultiError ¶
type GetAggregatedRatingResponseMultiError []error
GetAggregatedRatingResponseMultiError is an error wrapping multiple validation errors returned by GetAggregatedRatingResponse.ValidateAll() if the designated constraints aren't met.
func (GetAggregatedRatingResponseMultiError) AllErrors ¶
func (m GetAggregatedRatingResponseMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (GetAggregatedRatingResponseMultiError) Error ¶
func (m GetAggregatedRatingResponseMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type GetAggregatedRatingResponseValidationError ¶
type GetAggregatedRatingResponseValidationError struct {
// contains filtered or unexported fields
}
GetAggregatedRatingResponseValidationError is the validation error returned by GetAggregatedRatingResponse.Validate if the designated constraints aren't met.
func (GetAggregatedRatingResponseValidationError) Cause ¶
func (e GetAggregatedRatingResponseValidationError) Cause() error
Cause function returns cause value.
func (GetAggregatedRatingResponseValidationError) Error ¶
func (e GetAggregatedRatingResponseValidationError) Error() string
Error satisfies the builtin error interface
func (GetAggregatedRatingResponseValidationError) ErrorName ¶
func (e GetAggregatedRatingResponseValidationError) ErrorName() string
ErrorName returns error name.
func (GetAggregatedRatingResponseValidationError) Field ¶
func (e GetAggregatedRatingResponseValidationError) Field() string
Field function returns field value.
func (GetAggregatedRatingResponseValidationError) Key ¶
func (e GetAggregatedRatingResponseValidationError) Key() bool
Key function returns key value.
func (GetAggregatedRatingResponseValidationError) Reason ¶
func (e GetAggregatedRatingResponseValidationError) Reason() string
Reason function returns reason value.
type PushMsg ¶
type PushMsg struct { Type PushMsg_Type `protobuf:"varint,1,opt,name=type,proto3,enum=rating.service.v1.PushMsg_Type" json:"type,omitempty"` Key string `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"` Msg []byte `protobuf:"bytes,3,opt,name=msg,proto3" json:"msg,omitempty"` // contains filtered or unexported fields }
func (*PushMsg) Descriptor
deprecated
func (*PushMsg) GetType ¶
func (x *PushMsg) GetType() PushMsg_Type
func (*PushMsg) ProtoMessage ¶
func (*PushMsg) ProtoMessage()
func (*PushMsg) ProtoReflect ¶
func (x *PushMsg) ProtoReflect() protoreflect.Message
func (*PushMsg) Validate ¶
Validate checks the field values on PushMsg 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 (*PushMsg) ValidateAll ¶
ValidateAll checks the field values on PushMsg 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 PushMsgMultiError, or nil if none found.
type PushMsgMultiError ¶
type PushMsgMultiError []error
PushMsgMultiError is an error wrapping multiple validation errors returned by PushMsg.ValidateAll() if the designated constraints aren't met.
func (PushMsgMultiError) AllErrors ¶
func (m PushMsgMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (PushMsgMultiError) Error ¶
func (m PushMsgMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type PushMsgValidationError ¶
type PushMsgValidationError struct {
// contains filtered or unexported fields
}
PushMsgValidationError is the validation error returned by PushMsg.Validate if the designated constraints aren't met.
func (PushMsgValidationError) Cause ¶
func (e PushMsgValidationError) Cause() error
Cause function returns cause value.
func (PushMsgValidationError) Error ¶
func (e PushMsgValidationError) Error() string
Error satisfies the builtin error interface
func (PushMsgValidationError) ErrorName ¶
func (e PushMsgValidationError) ErrorName() string
ErrorName returns error name.
func (PushMsgValidationError) Field ¶
func (e PushMsgValidationError) Field() string
Field function returns field value.
func (PushMsgValidationError) Key ¶
func (e PushMsgValidationError) Key() bool
Key function returns key value.
func (PushMsgValidationError) Reason ¶
func (e PushMsgValidationError) Reason() string
Reason function returns reason value.
type PushMsg_Type ¶
type PushMsg_Type int32
const ( PushMsg_TYPE_UNSPECIFIED PushMsg_Type = 0 PushMsg_TYPE_METADATA_CREATE PushMsg_Type = 1 PushMsg_TYPE_METADATA_DELETE PushMsg_Type = 2 )
func (PushMsg_Type) Descriptor ¶
func (PushMsg_Type) Descriptor() protoreflect.EnumDescriptor
func (PushMsg_Type) Enum ¶
func (x PushMsg_Type) Enum() *PushMsg_Type
func (PushMsg_Type) EnumDescriptor
deprecated
func (PushMsg_Type) EnumDescriptor() ([]byte, []int)
Deprecated: Use PushMsg_Type.Descriptor instead.
func (PushMsg_Type) Number ¶
func (x PushMsg_Type) Number() protoreflect.EnumNumber
func (PushMsg_Type) String ¶
func (x PushMsg_Type) String() string
func (PushMsg_Type) Type ¶
func (PushMsg_Type) Type() protoreflect.EnumType
type RECORDTYPE ¶
type RECORDTYPE int32
const ( RECORDTYPE_RECORDTYPE_UNSPECIFIED RECORDTYPE = 0 RECORDTYPE_RECORDTYPE_MOVIE RECORDTYPE = 1 )
func (RECORDTYPE) Descriptor ¶
func (RECORDTYPE) Descriptor() protoreflect.EnumDescriptor
func (RECORDTYPE) Enum ¶
func (x RECORDTYPE) Enum() *RECORDTYPE
func (RECORDTYPE) EnumDescriptor
deprecated
func (RECORDTYPE) EnumDescriptor() ([]byte, []int)
Deprecated: Use RECORDTYPE.Descriptor instead.
func (RECORDTYPE) Number ¶
func (x RECORDTYPE) Number() protoreflect.EnumNumber
func (RECORDTYPE) String ¶
func (x RECORDTYPE) String() string
func (RECORDTYPE) Type ¶
func (RECORDTYPE) Type() protoreflect.EnumType
type Rating ¶
type Rating struct { RecordType RECORDTYPE `` /* 126-byte string literal not displayed */ RecordId uint64 `protobuf:"varint,2,opt,name=record_id,json=recordId,proto3" json:"record_id,omitempty"` UserId uint64 `protobuf:"varint,3,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` RatingValue uint32 `protobuf:"varint,4,opt,name=rating_value,json=ratingValue,proto3" json:"rating_value,omitempty"` // contains filtered or unexported fields }
func (*Rating) Descriptor
deprecated
func (*Rating) GetRatingValue ¶
func (*Rating) GetRecordId ¶
func (*Rating) GetRecordType ¶
func (x *Rating) GetRecordType() RECORDTYPE
func (*Rating) ProtoMessage ¶
func (*Rating) ProtoMessage()
func (*Rating) ProtoReflect ¶
func (x *Rating) ProtoReflect() protoreflect.Message
func (*Rating) Validate ¶
Validate checks the field values on Rating 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 (*Rating) ValidateAll ¶
ValidateAll checks the field values on Rating 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 RatingMultiError, or nil if none found.
type RatingMultiError ¶
type RatingMultiError []error
RatingMultiError is an error wrapping multiple validation errors returned by Rating.ValidateAll() if the designated constraints aren't met.
func (RatingMultiError) AllErrors ¶
func (m RatingMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (RatingMultiError) Error ¶
func (m RatingMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type RatingServiceClient ¶
type RatingServiceClient interface { GetAggregatedRating(ctx context.Context, in *GetAggregatedRatingRequest, opts ...grpc.CallOption) (*GetAggregatedRatingResponse, error) CreateRating(ctx context.Context, in *CreateRatingRequest, opts ...grpc.CallOption) (*CreateRatingResponse, error) }
RatingServiceClient is the client API for RatingService 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 NewRatingServiceClient ¶
func NewRatingServiceClient(cc grpc.ClientConnInterface) RatingServiceClient
type RatingServiceHTTPClient ¶
type RatingServiceHTTPClient interface { CreateRating(ctx context.Context, req *CreateRatingRequest, opts ...http.CallOption) (rsp *CreateRatingResponse, err error) GetAggregatedRating(ctx context.Context, req *GetAggregatedRatingRequest, opts ...http.CallOption) (rsp *GetAggregatedRatingResponse, err error) }
func NewRatingServiceHTTPClient ¶
func NewRatingServiceHTTPClient(client *http.Client) RatingServiceHTTPClient
type RatingServiceHTTPClientImpl ¶
type RatingServiceHTTPClientImpl struct {
// contains filtered or unexported fields
}
func (*RatingServiceHTTPClientImpl) CreateRating ¶
func (c *RatingServiceHTTPClientImpl) CreateRating(ctx context.Context, in *CreateRatingRequest, opts ...http.CallOption) (*CreateRatingResponse, error)
func (*RatingServiceHTTPClientImpl) GetAggregatedRating ¶
func (c *RatingServiceHTTPClientImpl) GetAggregatedRating(ctx context.Context, in *GetAggregatedRatingRequest, opts ...http.CallOption) (*GetAggregatedRatingResponse, error)
type RatingServiceHTTPServer ¶
type RatingServiceHTTPServer interface { CreateRating(context.Context, *CreateRatingRequest) (*CreateRatingResponse, error) GetAggregatedRating(context.Context, *GetAggregatedRatingRequest) (*GetAggregatedRatingResponse, error) }
type RatingServiceServer ¶
type RatingServiceServer interface { GetAggregatedRating(context.Context, *GetAggregatedRatingRequest) (*GetAggregatedRatingResponse, error) CreateRating(context.Context, *CreateRatingRequest) (*CreateRatingResponse, error) // contains filtered or unexported methods }
RatingServiceServer is the server API for RatingService service. All implementations must embed UnimplementedRatingServiceServer for forward compatibility
type RatingValidationError ¶
type RatingValidationError struct {
// contains filtered or unexported fields
}
RatingValidationError is the validation error returned by Rating.Validate if the designated constraints aren't met.
func (RatingValidationError) Cause ¶
func (e RatingValidationError) Cause() error
Cause function returns cause value.
func (RatingValidationError) Error ¶
func (e RatingValidationError) Error() string
Error satisfies the builtin error interface
func (RatingValidationError) ErrorName ¶
func (e RatingValidationError) ErrorName() string
ErrorName returns error name.
func (RatingValidationError) Field ¶
func (e RatingValidationError) Field() string
Field function returns field value.
func (RatingValidationError) Key ¶
func (e RatingValidationError) Key() bool
Key function returns key value.
func (RatingValidationError) Reason ¶
func (e RatingValidationError) Reason() string
Reason function returns reason value.
type UnimplementedRatingServiceServer ¶
type UnimplementedRatingServiceServer struct { }
UnimplementedRatingServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedRatingServiceServer) CreateRating ¶
func (UnimplementedRatingServiceServer) CreateRating(context.Context, *CreateRatingRequest) (*CreateRatingResponse, error)
func (UnimplementedRatingServiceServer) GetAggregatedRating ¶
func (UnimplementedRatingServiceServer) GetAggregatedRating(context.Context, *GetAggregatedRatingRequest) (*GetAggregatedRatingResponse, error)
type UnsafeRatingServiceServer ¶
type UnsafeRatingServiceServer interface {
// contains filtered or unexported methods
}
UnsafeRatingServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to RatingServiceServer will result in compilation errors.