Documentation
¶
Index ¶
- Constants
- Variables
- func RegisterRedemptionServiceHTTPServer(s *http.Server, srv RedemptionServiceHTTPServer)
- func RegisterRedemptionServiceServer(s grpc.ServiceRegistrar, srv RedemptionServiceServer)
- type RedeemCodeReply
- func (*RedeemCodeReply) Descriptor() ([]byte, []int)deprecated
- func (x *RedeemCodeReply) GetMessage() string
- func (*RedeemCodeReply) ProtoMessage()
- func (x *RedeemCodeReply) ProtoReflect() protoreflect.Message
- func (x *RedeemCodeReply) Reset()
- func (x *RedeemCodeReply) String() string
- func (m *RedeemCodeReply) Validate() error
- func (m *RedeemCodeReply) ValidateAll() error
- type RedeemCodeReplyMultiError
- type RedeemCodeReplyValidationError
- func (e RedeemCodeReplyValidationError) Cause() error
- func (e RedeemCodeReplyValidationError) Error() string
- func (e RedeemCodeReplyValidationError) ErrorName() string
- func (e RedeemCodeReplyValidationError) Field() string
- func (e RedeemCodeReplyValidationError) Key() bool
- func (e RedeemCodeReplyValidationError) Reason() string
- type RedeemCodeRequest
- func (*RedeemCodeRequest) Descriptor() ([]byte, []int)deprecated
- func (x *RedeemCodeRequest) GetCode() string
- func (*RedeemCodeRequest) ProtoMessage()
- func (x *RedeemCodeRequest) ProtoReflect() protoreflect.Message
- func (x *RedeemCodeRequest) Reset()
- func (x *RedeemCodeRequest) String() string
- func (m *RedeemCodeRequest) Validate() error
- func (m *RedeemCodeRequest) ValidateAll() error
- type RedeemCodeRequestMultiError
- type RedeemCodeRequestValidationError
- func (e RedeemCodeRequestValidationError) Cause() error
- func (e RedeemCodeRequestValidationError) Error() string
- func (e RedeemCodeRequestValidationError) ErrorName() string
- func (e RedeemCodeRequestValidationError) Field() string
- func (e RedeemCodeRequestValidationError) Key() bool
- func (e RedeemCodeRequestValidationError) Reason() string
- type RedemptionServiceClient
- type RedemptionServiceHTTPClient
- type RedemptionServiceHTTPClientImpl
- type RedemptionServiceHTTPServer
- type RedemptionServiceServer
- type UnimplementedRedemptionServiceServer
- type UnsafeRedemptionServiceServer
Constants ¶
const OperationRedemptionServiceRedeemCode = "/api.public.redemption.v1.RedemptionService/RedeemCode"
const (
RedemptionService_RedeemCode_FullMethodName = "/api.public.redemption.v1.RedemptionService/RedeemCode"
)
Variables ¶
var File_public_redemption_v1_redemption_proto protoreflect.FileDescriptor
var RedemptionService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "api.public.redemption.v1.RedemptionService", HandlerType: (*RedemptionServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "RedeemCode", Handler: _RedemptionService_RedeemCode_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "public/redemption/v1/redemption.proto", }
RedemptionService_ServiceDesc is the grpc.ServiceDesc for RedemptionService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterRedemptionServiceHTTPServer ¶
func RegisterRedemptionServiceHTTPServer(s *http.Server, srv RedemptionServiceHTTPServer)
func RegisterRedemptionServiceServer ¶
func RegisterRedemptionServiceServer(s grpc.ServiceRegistrar, srv RedemptionServiceServer)
Types ¶
type RedeemCodeReply ¶
type RedeemCodeReply struct {
Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
// contains filtered or unexported fields
}
RedeemCodeReply 兑换码响应
func (*RedeemCodeReply) Descriptor
deprecated
func (*RedeemCodeReply) Descriptor() ([]byte, []int)
Deprecated: Use RedeemCodeReply.ProtoReflect.Descriptor instead.
func (*RedeemCodeReply) GetMessage ¶
func (x *RedeemCodeReply) GetMessage() string
func (*RedeemCodeReply) ProtoMessage ¶
func (*RedeemCodeReply) ProtoMessage()
func (*RedeemCodeReply) ProtoReflect ¶
func (x *RedeemCodeReply) ProtoReflect() protoreflect.Message
func (*RedeemCodeReply) Reset ¶
func (x *RedeemCodeReply) Reset()
func (*RedeemCodeReply) String ¶
func (x *RedeemCodeReply) String() string
func (*RedeemCodeReply) Validate ¶
func (m *RedeemCodeReply) Validate() error
Validate checks the field values on RedeemCodeReply 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 (*RedeemCodeReply) ValidateAll ¶
func (m *RedeemCodeReply) ValidateAll() error
ValidateAll checks the field values on RedeemCodeReply 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 RedeemCodeReplyMultiError, or nil if none found.
type RedeemCodeReplyMultiError ¶
type RedeemCodeReplyMultiError []error
RedeemCodeReplyMultiError is an error wrapping multiple validation errors returned by RedeemCodeReply.ValidateAll() if the designated constraints aren't met.
func (RedeemCodeReplyMultiError) AllErrors ¶
func (m RedeemCodeReplyMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (RedeemCodeReplyMultiError) Error ¶
func (m RedeemCodeReplyMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type RedeemCodeReplyValidationError ¶
type RedeemCodeReplyValidationError struct {
// contains filtered or unexported fields
}
RedeemCodeReplyValidationError is the validation error returned by RedeemCodeReply.Validate if the designated constraints aren't met.
func (RedeemCodeReplyValidationError) Cause ¶
func (e RedeemCodeReplyValidationError) Cause() error
Cause function returns cause value.
func (RedeemCodeReplyValidationError) Error ¶
func (e RedeemCodeReplyValidationError) Error() string
Error satisfies the builtin error interface
func (RedeemCodeReplyValidationError) ErrorName ¶
func (e RedeemCodeReplyValidationError) ErrorName() string
ErrorName returns error name.
func (RedeemCodeReplyValidationError) Field ¶
func (e RedeemCodeReplyValidationError) Field() string
Field function returns field value.
func (RedeemCodeReplyValidationError) Key ¶
func (e RedeemCodeReplyValidationError) Key() bool
Key function returns key value.
func (RedeemCodeReplyValidationError) Reason ¶
func (e RedeemCodeReplyValidationError) Reason() string
Reason function returns reason value.
type RedeemCodeRequest ¶
type RedeemCodeRequest struct {
Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` // 兑换码
// contains filtered or unexported fields
}
RedeemCodeRequest 兑换码请求
func (*RedeemCodeRequest) Descriptor
deprecated
func (*RedeemCodeRequest) Descriptor() ([]byte, []int)
Deprecated: Use RedeemCodeRequest.ProtoReflect.Descriptor instead.
func (*RedeemCodeRequest) GetCode ¶
func (x *RedeemCodeRequest) GetCode() string
func (*RedeemCodeRequest) ProtoMessage ¶
func (*RedeemCodeRequest) ProtoMessage()
func (*RedeemCodeRequest) ProtoReflect ¶
func (x *RedeemCodeRequest) ProtoReflect() protoreflect.Message
func (*RedeemCodeRequest) Reset ¶
func (x *RedeemCodeRequest) Reset()
func (*RedeemCodeRequest) String ¶
func (x *RedeemCodeRequest) String() string
func (*RedeemCodeRequest) Validate ¶
func (m *RedeemCodeRequest) Validate() error
Validate checks the field values on RedeemCodeRequest 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 (*RedeemCodeRequest) ValidateAll ¶
func (m *RedeemCodeRequest) ValidateAll() error
ValidateAll checks the field values on RedeemCodeRequest 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 RedeemCodeRequestMultiError, or nil if none found.
type RedeemCodeRequestMultiError ¶
type RedeemCodeRequestMultiError []error
RedeemCodeRequestMultiError is an error wrapping multiple validation errors returned by RedeemCodeRequest.ValidateAll() if the designated constraints aren't met.
func (RedeemCodeRequestMultiError) AllErrors ¶
func (m RedeemCodeRequestMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (RedeemCodeRequestMultiError) Error ¶
func (m RedeemCodeRequestMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type RedeemCodeRequestValidationError ¶
type RedeemCodeRequestValidationError struct {
// contains filtered or unexported fields
}
RedeemCodeRequestValidationError is the validation error returned by RedeemCodeRequest.Validate if the designated constraints aren't met.
func (RedeemCodeRequestValidationError) Cause ¶
func (e RedeemCodeRequestValidationError) Cause() error
Cause function returns cause value.
func (RedeemCodeRequestValidationError) Error ¶
func (e RedeemCodeRequestValidationError) Error() string
Error satisfies the builtin error interface
func (RedeemCodeRequestValidationError) ErrorName ¶
func (e RedeemCodeRequestValidationError) ErrorName() string
ErrorName returns error name.
func (RedeemCodeRequestValidationError) Field ¶
func (e RedeemCodeRequestValidationError) Field() string
Field function returns field value.
func (RedeemCodeRequestValidationError) Key ¶
func (e RedeemCodeRequestValidationError) Key() bool
Key function returns key value.
func (RedeemCodeRequestValidationError) Reason ¶
func (e RedeemCodeRequestValidationError) Reason() string
Reason function returns reason value.
type RedemptionServiceClient ¶
type RedemptionServiceClient interface {
// RedeemCode 兑换兑换码
RedeemCode(ctx context.Context, in *RedeemCodeRequest, opts ...grpc.CallOption) (*RedeemCodeReply, error)
}
RedemptionServiceClient is the client API for RedemptionService 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.
RedemptionService 兑换码服务
func NewRedemptionServiceClient ¶
func NewRedemptionServiceClient(cc grpc.ClientConnInterface) RedemptionServiceClient
type RedemptionServiceHTTPClient ¶
type RedemptionServiceHTTPClient interface {
// RedeemCode RedeemCode 兑换兑换码
RedeemCode(ctx context.Context, req *RedeemCodeRequest, opts ...http.CallOption) (rsp *RedeemCodeReply, err error)
}
func NewRedemptionServiceHTTPClient ¶
func NewRedemptionServiceHTTPClient(client *http.Client) RedemptionServiceHTTPClient
type RedemptionServiceHTTPClientImpl ¶
type RedemptionServiceHTTPClientImpl struct {
// contains filtered or unexported fields
}
func (*RedemptionServiceHTTPClientImpl) RedeemCode ¶
func (c *RedemptionServiceHTTPClientImpl) RedeemCode(ctx context.Context, in *RedeemCodeRequest, opts ...http.CallOption) (*RedeemCodeReply, error)
RedeemCode RedeemCode 兑换兑换码
type RedemptionServiceHTTPServer ¶
type RedemptionServiceHTTPServer interface {
// RedeemCode RedeemCode 兑换兑换码
RedeemCode(context.Context, *RedeemCodeRequest) (*RedeemCodeReply, error)
}
type RedemptionServiceServer ¶
type RedemptionServiceServer interface {
// RedeemCode 兑换兑换码
RedeemCode(context.Context, *RedeemCodeRequest) (*RedeemCodeReply, error)
// contains filtered or unexported methods
}
RedemptionServiceServer is the server API for RedemptionService service. All implementations must embed UnimplementedRedemptionServiceServer for forward compatibility.
RedemptionService 兑换码服务
type UnimplementedRedemptionServiceServer ¶
type UnimplementedRedemptionServiceServer struct{}
UnimplementedRedemptionServiceServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedRedemptionServiceServer) RedeemCode ¶
func (UnimplementedRedemptionServiceServer) RedeemCode(context.Context, *RedeemCodeRequest) (*RedeemCodeReply, error)
type UnsafeRedemptionServiceServer ¶
type UnsafeRedemptionServiceServer interface {
// contains filtered or unexported methods
}
UnsafeRedemptionServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to RedemptionServiceServer will result in compilation errors.