notificationv1

package
v0.0.27 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 29, 2025 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NotificationService_Send_FullMethodName           = "/notification.v1.NotificationService/Send"
	NotificationService_AsyncSend_FullMethodName      = "/notification.v1.NotificationService/AsyncSend"
	NotificationService_BatchSend_FullMethodName      = "/notification.v1.NotificationService/BatchSend"
	NotificationService_AsyncBatchSend_FullMethodName = "/notification.v1.NotificationService/AsyncBatchSend"
)

Variables

View Source
var (
	SendStatus_name = map[int32]string{
		0: "STATUS_UNSPECIFIED",
		1: "PREPARE",
		2: "PENDING",
		3: "SUCCESS",
		4: "FAILURE",
		5: "CANCEL",
	}
	SendStatus_value = map[string]int32{
		"STATUS_UNSPECIFIED": 0,
		"PREPARE":            1,
		"PENDING":            2,
		"SUCCESS":            3,
		"FAILURE":            4,
		"CANCEL":             5,
	}
)

Enum value maps for SendStatus.

View Source
var File_notification_v1_notification_proto protoreflect.FileDescriptor
View Source
var NotificationService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "notification.v1.NotificationService",
	HandlerType: (*NotificationServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Send",
			Handler:    _NotificationService_Send_Handler,
		},
		{
			MethodName: "AsyncSend",
			Handler:    _NotificationService_AsyncSend_Handler,
		},
		{
			MethodName: "BatchSend",
			Handler:    _NotificationService_BatchSend_Handler,
		},
		{
			MethodName: "AsyncBatchSend",
			Handler:    _NotificationService_AsyncBatchSend_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "notification/v1/notification.proto",
}

NotificationService_ServiceDesc is the grpc.ServiceDesc for NotificationService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterNotificationServiceServer

func RegisterNotificationServiceServer(s grpc.ServiceRegistrar, srv NotificationServiceServer)

Types

type AsyncBatchSendRequest

type AsyncBatchSendRequest struct {
	Notifications []*Notification `protobuf:"bytes,1,rep,name=notifications,proto3" json:"notifications,omitempty"`
	// contains filtered or unexported fields
}

批量消息异步发送请求

func (*AsyncBatchSendRequest) Descriptor deprecated

func (*AsyncBatchSendRequest) Descriptor() ([]byte, []int)

Deprecated: Use AsyncBatchSendRequest.ProtoReflect.Descriptor instead.

func (*AsyncBatchSendRequest) GetNotifications

func (x *AsyncBatchSendRequest) GetNotifications() []*Notification

func (*AsyncBatchSendRequest) ProtoMessage

func (*AsyncBatchSendRequest) ProtoMessage()

func (*AsyncBatchSendRequest) ProtoReflect

func (x *AsyncBatchSendRequest) ProtoReflect() protoreflect.Message

func (*AsyncBatchSendRequest) Reset

func (x *AsyncBatchSendRequest) Reset()

func (*AsyncBatchSendRequest) String

func (x *AsyncBatchSendRequest) String() string

func (*AsyncBatchSendRequest) Validate

func (m *AsyncBatchSendRequest) Validate() error

Validate checks the field values on AsyncBatchSendRequest 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 (*AsyncBatchSendRequest) ValidateAll

func (m *AsyncBatchSendRequest) ValidateAll() error

ValidateAll checks the field values on AsyncBatchSendRequest 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 AsyncBatchSendRequestMultiError, or nil if none found.

type AsyncBatchSendRequestMultiError

type AsyncBatchSendRequestMultiError []error

AsyncBatchSendRequestMultiError is an error wrapping multiple validation errors returned by AsyncBatchSendRequest.ValidateAll() if the designated constraints aren't met.

func (AsyncBatchSendRequestMultiError) AllErrors

func (m AsyncBatchSendRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (AsyncBatchSendRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type AsyncBatchSendRequestValidationError

type AsyncBatchSendRequestValidationError struct {
	// contains filtered or unexported fields
}

AsyncBatchSendRequestValidationError is the validation error returned by AsyncBatchSendRequest.Validate if the designated constraints aren't met.

func (AsyncBatchSendRequestValidationError) Cause

Cause function returns cause value.

func (AsyncBatchSendRequestValidationError) Error

Error satisfies the builtin error interface

func (AsyncBatchSendRequestValidationError) ErrorName

ErrorName returns error name.

func (AsyncBatchSendRequestValidationError) Field

Field function returns field value.

func (AsyncBatchSendRequestValidationError) Key

Key function returns key value.

func (AsyncBatchSendRequestValidationError) Reason

Reason function returns reason value.

type AsyncBatchSendResponse

type AsyncBatchSendResponse struct {
	NotificationIds []uint64 `protobuf:"varint,1,rep,packed,name=notification_ids,json=notificationIds,proto3" json:"notification_ids,omitempty"`
	// contains filtered or unexported fields
}

批量消息异步发送响应

func (*AsyncBatchSendResponse) Descriptor deprecated

func (*AsyncBatchSendResponse) Descriptor() ([]byte, []int)

Deprecated: Use AsyncBatchSendResponse.ProtoReflect.Descriptor instead.

func (*AsyncBatchSendResponse) GetNotificationIds

func (x *AsyncBatchSendResponse) GetNotificationIds() []uint64

func (*AsyncBatchSendResponse) ProtoMessage

func (*AsyncBatchSendResponse) ProtoMessage()

func (*AsyncBatchSendResponse) ProtoReflect

func (x *AsyncBatchSendResponse) ProtoReflect() protoreflect.Message

func (*AsyncBatchSendResponse) Reset

func (x *AsyncBatchSendResponse) Reset()

func (*AsyncBatchSendResponse) String

func (x *AsyncBatchSendResponse) String() string

func (*AsyncBatchSendResponse) Validate

func (m *AsyncBatchSendResponse) Validate() error

Validate checks the field values on AsyncBatchSendResponse 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 (*AsyncBatchSendResponse) ValidateAll

func (m *AsyncBatchSendResponse) ValidateAll() error

ValidateAll checks the field values on AsyncBatchSendResponse 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 AsyncBatchSendResponseMultiError, or nil if none found.

type AsyncBatchSendResponseMultiError

type AsyncBatchSendResponseMultiError []error

AsyncBatchSendResponseMultiError is an error wrapping multiple validation errors returned by AsyncBatchSendResponse.ValidateAll() if the designated constraints aren't met.

func (AsyncBatchSendResponseMultiError) AllErrors

func (m AsyncBatchSendResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (AsyncBatchSendResponseMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type AsyncBatchSendResponseValidationError

type AsyncBatchSendResponseValidationError struct {
	// contains filtered or unexported fields
}

AsyncBatchSendResponseValidationError is the validation error returned by AsyncBatchSendResponse.Validate if the designated constraints aren't met.

func (AsyncBatchSendResponseValidationError) Cause

Cause function returns cause value.

func (AsyncBatchSendResponseValidationError) Error

Error satisfies the builtin error interface

func (AsyncBatchSendResponseValidationError) ErrorName

ErrorName returns error name.

func (AsyncBatchSendResponseValidationError) Field

Field function returns field value.

func (AsyncBatchSendResponseValidationError) Key

Key function returns key value.

func (AsyncBatchSendResponseValidationError) Reason

Reason function returns reason value.

type AsyncSendRequest

type AsyncSendRequest struct {
	Notification *Notification `protobuf:"bytes,1,opt,name=notification,proto3" json:"notification,omitempty"`
	// contains filtered or unexported fields
}

单条消息异步发送请求

func (*AsyncSendRequest) Descriptor deprecated

func (*AsyncSendRequest) Descriptor() ([]byte, []int)

Deprecated: Use AsyncSendRequest.ProtoReflect.Descriptor instead.

func (*AsyncSendRequest) GetNotification

func (x *AsyncSendRequest) GetNotification() *Notification

func (*AsyncSendRequest) ProtoMessage

func (*AsyncSendRequest) ProtoMessage()

func (*AsyncSendRequest) ProtoReflect

func (x *AsyncSendRequest) ProtoReflect() protoreflect.Message

func (*AsyncSendRequest) Reset

func (x *AsyncSendRequest) Reset()

func (*AsyncSendRequest) String

func (x *AsyncSendRequest) String() string

func (*AsyncSendRequest) Validate

func (m *AsyncSendRequest) Validate() error

Validate checks the field values on AsyncSendRequest 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 (*AsyncSendRequest) ValidateAll

func (m *AsyncSendRequest) ValidateAll() error

ValidateAll checks the field values on AsyncSendRequest 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 AsyncSendRequestMultiError, or nil if none found.

type AsyncSendRequestMultiError

type AsyncSendRequestMultiError []error

AsyncSendRequestMultiError is an error wrapping multiple validation errors returned by AsyncSendRequest.ValidateAll() if the designated constraints aren't met.

func (AsyncSendRequestMultiError) AllErrors

func (m AsyncSendRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (AsyncSendRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type AsyncSendRequestValidationError

type AsyncSendRequestValidationError struct {
	// contains filtered or unexported fields
}

AsyncSendRequestValidationError is the validation error returned by AsyncSendRequest.Validate if the designated constraints aren't met.

func (AsyncSendRequestValidationError) Cause

Cause function returns cause value.

func (AsyncSendRequestValidationError) Error

Error satisfies the builtin error interface

func (AsyncSendRequestValidationError) ErrorName

ErrorName returns error name.

func (AsyncSendRequestValidationError) Field

Field function returns field value.

func (AsyncSendRequestValidationError) Key

Key function returns key value.

func (AsyncSendRequestValidationError) Reason

Reason function returns reason value.

type AsyncSendResponse

type AsyncSendResponse struct {
	Result *SendResult `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"`
	// contains filtered or unexported fields
}

单条消息异步发送响应

func (*AsyncSendResponse) Descriptor deprecated

func (*AsyncSendResponse) Descriptor() ([]byte, []int)

Deprecated: Use AsyncSendResponse.ProtoReflect.Descriptor instead.

func (*AsyncSendResponse) GetResult

func (x *AsyncSendResponse) GetResult() *SendResult

func (*AsyncSendResponse) ProtoMessage

func (*AsyncSendResponse) ProtoMessage()

func (*AsyncSendResponse) ProtoReflect

func (x *AsyncSendResponse) ProtoReflect() protoreflect.Message

func (*AsyncSendResponse) Reset

func (x *AsyncSendResponse) Reset()

func (*AsyncSendResponse) String

func (x *AsyncSendResponse) String() string

func (*AsyncSendResponse) Validate

func (m *AsyncSendResponse) Validate() error

Validate checks the field values on AsyncSendResponse 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 (*AsyncSendResponse) ValidateAll

func (m *AsyncSendResponse) ValidateAll() error

ValidateAll checks the field values on AsyncSendResponse 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 AsyncSendResponseMultiError, or nil if none found.

type AsyncSendResponseMultiError

type AsyncSendResponseMultiError []error

AsyncSendResponseMultiError is an error wrapping multiple validation errors returned by AsyncSendResponse.ValidateAll() if the designated constraints aren't met.

func (AsyncSendResponseMultiError) AllErrors

func (m AsyncSendResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (AsyncSendResponseMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type AsyncSendResponseValidationError

type AsyncSendResponseValidationError struct {
	// contains filtered or unexported fields
}

AsyncSendResponseValidationError is the validation error returned by AsyncSendResponse.Validate if the designated constraints aren't met.

func (AsyncSendResponseValidationError) Cause

Cause function returns cause value.

func (AsyncSendResponseValidationError) Error

Error satisfies the builtin error interface

func (AsyncSendResponseValidationError) ErrorName

ErrorName returns error name.

func (AsyncSendResponseValidationError) Field

Field function returns field value.

func (AsyncSendResponseValidationError) Key

Key function returns key value.

func (AsyncSendResponseValidationError) Reason

Reason function returns reason value.

type BatchSendRequest

type BatchSendRequest struct {
	Notifications []*Notification `protobuf:"bytes,1,rep,name=notifications,proto3" json:"notifications,omitempty"`
	// contains filtered or unexported fields
}

批量消息发送请求

func (*BatchSendRequest) Descriptor deprecated

func (*BatchSendRequest) Descriptor() ([]byte, []int)

Deprecated: Use BatchSendRequest.ProtoReflect.Descriptor instead.

func (*BatchSendRequest) GetNotifications

func (x *BatchSendRequest) GetNotifications() []*Notification

func (*BatchSendRequest) ProtoMessage

func (*BatchSendRequest) ProtoMessage()

func (*BatchSendRequest) ProtoReflect

func (x *BatchSendRequest) ProtoReflect() protoreflect.Message

func (*BatchSendRequest) Reset

func (x *BatchSendRequest) Reset()

func (*BatchSendRequest) String

func (x *BatchSendRequest) String() string

func (*BatchSendRequest) Validate

func (m *BatchSendRequest) Validate() error

Validate checks the field values on BatchSendRequest 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 (*BatchSendRequest) ValidateAll

func (m *BatchSendRequest) ValidateAll() error

ValidateAll checks the field values on BatchSendRequest 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 BatchSendRequestMultiError, or nil if none found.

type BatchSendRequestMultiError

type BatchSendRequestMultiError []error

BatchSendRequestMultiError is an error wrapping multiple validation errors returned by BatchSendRequest.ValidateAll() if the designated constraints aren't met.

func (BatchSendRequestMultiError) AllErrors

func (m BatchSendRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (BatchSendRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type BatchSendRequestValidationError

type BatchSendRequestValidationError struct {
	// contains filtered or unexported fields
}

BatchSendRequestValidationError is the validation error returned by BatchSendRequest.Validate if the designated constraints aren't met.

func (BatchSendRequestValidationError) Cause

Cause function returns cause value.

func (BatchSendRequestValidationError) Error

Error satisfies the builtin error interface

func (BatchSendRequestValidationError) ErrorName

ErrorName returns error name.

func (BatchSendRequestValidationError) Field

Field function returns field value.

func (BatchSendRequestValidationError) Key

Key function returns key value.

func (BatchSendRequestValidationError) Reason

Reason function returns reason value.

type BatchSendResponse

type BatchSendResponse struct {
	Results    []*SendResult `protobuf:"bytes,1,rep,name=results,proto3" json:"results,omitempty"`
	TotalCnt   int32         `protobuf:"varint,2,opt,name=total_cnt,json=totalCnt,proto3" json:"total_cnt,omitempty"`
	SuccessCnt int32         `protobuf:"varint,3,opt,name=success_cnt,json=successCnt,proto3" json:"success_cnt,omitempty"`
	// contains filtered or unexported fields
}

批量消息发送响应

func (*BatchSendResponse) Descriptor deprecated

func (*BatchSendResponse) Descriptor() ([]byte, []int)

Deprecated: Use BatchSendResponse.ProtoReflect.Descriptor instead.

func (*BatchSendResponse) GetResults

func (x *BatchSendResponse) GetResults() []*SendResult

func (*BatchSendResponse) GetSuccessCnt

func (x *BatchSendResponse) GetSuccessCnt() int32

func (*BatchSendResponse) GetTotalCnt

func (x *BatchSendResponse) GetTotalCnt() int32

func (*BatchSendResponse) ProtoMessage

func (*BatchSendResponse) ProtoMessage()

func (*BatchSendResponse) ProtoReflect

func (x *BatchSendResponse) ProtoReflect() protoreflect.Message

func (*BatchSendResponse) Reset

func (x *BatchSendResponse) Reset()

func (*BatchSendResponse) String

func (x *BatchSendResponse) String() string

func (*BatchSendResponse) Validate

func (m *BatchSendResponse) Validate() error

Validate checks the field values on BatchSendResponse 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 (*BatchSendResponse) ValidateAll

func (m *BatchSendResponse) ValidateAll() error

ValidateAll checks the field values on BatchSendResponse 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 BatchSendResponseMultiError, or nil if none found.

type BatchSendResponseMultiError

type BatchSendResponseMultiError []error

BatchSendResponseMultiError is an error wrapping multiple validation errors returned by BatchSendResponse.ValidateAll() if the designated constraints aren't met.

func (BatchSendResponseMultiError) AllErrors

func (m BatchSendResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (BatchSendResponseMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type BatchSendResponseValidationError

type BatchSendResponseValidationError struct {
	// contains filtered or unexported fields
}

BatchSendResponseValidationError is the validation error returned by BatchSendResponse.Validate if the designated constraints aren't met.

func (BatchSendResponseValidationError) Cause

Cause function returns cause value.

func (BatchSendResponseValidationError) Error

Error satisfies the builtin error interface

func (BatchSendResponseValidationError) ErrorName

ErrorName returns error name.

func (BatchSendResponseValidationError) Field

Field function returns field value.

func (BatchSendResponseValidationError) Key

Key function returns key value.

func (BatchSendResponseValidationError) Reason

Reason function returns reason value.

type DeadlineStrategy

type DeadlineStrategy struct {
	Deadline *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=deadline,proto3" json:"deadline,omitempty"`
	// contains filtered or unexported fields
}

发送策略 - 截止时间前发送

func (*DeadlineStrategy) Descriptor deprecated

func (*DeadlineStrategy) Descriptor() ([]byte, []int)

Deprecated: Use DeadlineStrategy.ProtoReflect.Descriptor instead.

func (*DeadlineStrategy) GetDeadline

func (x *DeadlineStrategy) GetDeadline() *timestamppb.Timestamp

func (*DeadlineStrategy) ProtoMessage

func (*DeadlineStrategy) ProtoMessage()

func (*DeadlineStrategy) ProtoReflect

func (x *DeadlineStrategy) ProtoReflect() protoreflect.Message

func (*DeadlineStrategy) Reset

func (x *DeadlineStrategy) Reset()

func (*DeadlineStrategy) String

func (x *DeadlineStrategy) String() string

func (*DeadlineStrategy) Validate

func (m *DeadlineStrategy) Validate() error

Validate checks the field values on DeadlineStrategy 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 (*DeadlineStrategy) ValidateAll

func (m *DeadlineStrategy) ValidateAll() error

ValidateAll checks the field values on DeadlineStrategy 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 DeadlineStrategyMultiError, or nil if none found.

type DeadlineStrategyMultiError

type DeadlineStrategyMultiError []error

DeadlineStrategyMultiError is an error wrapping multiple validation errors returned by DeadlineStrategy.ValidateAll() if the designated constraints aren't met.

func (DeadlineStrategyMultiError) AllErrors

func (m DeadlineStrategyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DeadlineStrategyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type DeadlineStrategyValidationError

type DeadlineStrategyValidationError struct {
	// contains filtered or unexported fields
}

DeadlineStrategyValidationError is the validation error returned by DeadlineStrategy.Validate if the designated constraints aren't met.

func (DeadlineStrategyValidationError) Cause

Cause function returns cause value.

func (DeadlineStrategyValidationError) Error

Error satisfies the builtin error interface

func (DeadlineStrategyValidationError) ErrorName

ErrorName returns error name.

func (DeadlineStrategyValidationError) Field

Field function returns field value.

func (DeadlineStrategyValidationError) Key

Key function returns key value.

func (DeadlineStrategyValidationError) Reason

Reason function returns reason value.

type DelayedStrategy

type DelayedStrategy struct {
	DelaySeconds int64 `protobuf:"varint,1,opt,name=delay_seconds,json=delaySeconds,proto3" json:"delay_seconds,omitempty"`
	// contains filtered or unexported fields
}

发送策略 - 延迟发送

func (*DelayedStrategy) Descriptor deprecated

func (*DelayedStrategy) Descriptor() ([]byte, []int)

Deprecated: Use DelayedStrategy.ProtoReflect.Descriptor instead.

func (*DelayedStrategy) GetDelaySeconds

func (x *DelayedStrategy) GetDelaySeconds() int64

func (*DelayedStrategy) ProtoMessage

func (*DelayedStrategy) ProtoMessage()

func (*DelayedStrategy) ProtoReflect

func (x *DelayedStrategy) ProtoReflect() protoreflect.Message

func (*DelayedStrategy) Reset

func (x *DelayedStrategy) Reset()

func (*DelayedStrategy) String

func (x *DelayedStrategy) String() string

func (*DelayedStrategy) Validate

func (m *DelayedStrategy) Validate() error

Validate checks the field values on DelayedStrategy 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 (*DelayedStrategy) ValidateAll

func (m *DelayedStrategy) ValidateAll() error

ValidateAll checks the field values on DelayedStrategy 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 DelayedStrategyMultiError, or nil if none found.

type DelayedStrategyMultiError

type DelayedStrategyMultiError []error

DelayedStrategyMultiError is an error wrapping multiple validation errors returned by DelayedStrategy.ValidateAll() if the designated constraints aren't met.

func (DelayedStrategyMultiError) AllErrors

func (m DelayedStrategyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DelayedStrategyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type DelayedStrategyValidationError

type DelayedStrategyValidationError struct {
	// contains filtered or unexported fields
}

DelayedStrategyValidationError is the validation error returned by DelayedStrategy.Validate if the designated constraints aren't met.

func (DelayedStrategyValidationError) Cause

Cause function returns cause value.

func (DelayedStrategyValidationError) Error

Error satisfies the builtin error interface

func (DelayedStrategyValidationError) ErrorName

func (e DelayedStrategyValidationError) ErrorName() string

ErrorName returns error name.

func (DelayedStrategyValidationError) Field

Field function returns field value.

func (DelayedStrategyValidationError) Key

Key function returns key value.

func (DelayedStrategyValidationError) Reason

Reason function returns reason value.

type ImmediatelyStrategy

type ImmediatelyStrategy struct {
	// contains filtered or unexported fields
}

发送策略 - 立即发送

func (*ImmediatelyStrategy) Descriptor deprecated

func (*ImmediatelyStrategy) Descriptor() ([]byte, []int)

Deprecated: Use ImmediatelyStrategy.ProtoReflect.Descriptor instead.

func (*ImmediatelyStrategy) ProtoMessage

func (*ImmediatelyStrategy) ProtoMessage()

func (*ImmediatelyStrategy) ProtoReflect

func (x *ImmediatelyStrategy) ProtoReflect() protoreflect.Message

func (*ImmediatelyStrategy) Reset

func (x *ImmediatelyStrategy) Reset()

func (*ImmediatelyStrategy) String

func (x *ImmediatelyStrategy) String() string

func (*ImmediatelyStrategy) Validate

func (m *ImmediatelyStrategy) Validate() error

Validate checks the field values on ImmediatelyStrategy 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 (*ImmediatelyStrategy) ValidateAll

func (m *ImmediatelyStrategy) ValidateAll() error

ValidateAll checks the field values on ImmediatelyStrategy 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 ImmediatelyStrategyMultiError, or nil if none found.

type ImmediatelyStrategyMultiError

type ImmediatelyStrategyMultiError []error

ImmediatelyStrategyMultiError is an error wrapping multiple validation errors returned by ImmediatelyStrategy.ValidateAll() if the designated constraints aren't met.

func (ImmediatelyStrategyMultiError) AllErrors

func (m ImmediatelyStrategyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ImmediatelyStrategyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type ImmediatelyStrategyValidationError

type ImmediatelyStrategyValidationError struct {
	// contains filtered or unexported fields
}

ImmediatelyStrategyValidationError is the validation error returned by ImmediatelyStrategy.Validate if the designated constraints aren't met.

func (ImmediatelyStrategyValidationError) Cause

Cause function returns cause value.

func (ImmediatelyStrategyValidationError) Error

Error satisfies the builtin error interface

func (ImmediatelyStrategyValidationError) ErrorName

ErrorName returns error name.

func (ImmediatelyStrategyValidationError) Field

Field function returns field value.

func (ImmediatelyStrategyValidationError) Key

Key function returns key value.

func (ImmediatelyStrategyValidationError) Reason

Reason function returns reason value.

type Notification

type Notification struct {
	BizKey    string            `protobuf:"bytes,1,opt,name=biz_key,json=bizKey,proto3" json:"biz_key,omitempty"`
	Receivers []string          `protobuf:"bytes,2,rep,name=receivers,proto3" json:"receivers,omitempty"`
	Channel   v1.Channel        `protobuf:"varint,3,opt,name=channel,proto3,enum=common.v1.Channel" json:"channel,omitempty"`
	TplId     string            `protobuf:"bytes,4,opt,name=tpl_id,json=tplId,proto3" json:"tpl_id,omitempty"`
	TplParams map[string]string `` /* 162-byte string literal not displayed */
	Strategy  *SendStrategy     `protobuf:"bytes,6,opt,name=strategy,proto3" json:"strategy,omitempty"`
	// contains filtered or unexported fields
}

消息

func (*Notification) Descriptor deprecated

func (*Notification) Descriptor() ([]byte, []int)

Deprecated: Use Notification.ProtoReflect.Descriptor instead.

func (*Notification) GetBizKey

func (x *Notification) GetBizKey() string

func (*Notification) GetChannel

func (x *Notification) GetChannel() v1.Channel

func (*Notification) GetReceivers

func (x *Notification) GetReceivers() []string

func (*Notification) GetStrategy

func (x *Notification) GetStrategy() *SendStrategy

func (*Notification) GetTplId

func (x *Notification) GetTplId() string

func (*Notification) GetTplParams

func (x *Notification) GetTplParams() map[string]string

func (*Notification) ProtoMessage

func (*Notification) ProtoMessage()

func (*Notification) ProtoReflect

func (x *Notification) ProtoReflect() protoreflect.Message

func (*Notification) Reset

func (x *Notification) Reset()

func (*Notification) String

func (x *Notification) String() string

func (*Notification) Validate

func (m *Notification) Validate() error

Validate checks the field values on Notification 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 (*Notification) ValidateAll

func (m *Notification) ValidateAll() error

ValidateAll checks the field values on Notification 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 NotificationMultiError, or nil if none found.

type NotificationMultiError

type NotificationMultiError []error

NotificationMultiError is an error wrapping multiple validation errors returned by Notification.ValidateAll() if the designated constraints aren't met.

func (NotificationMultiError) AllErrors

func (m NotificationMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (NotificationMultiError) Error

func (m NotificationMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type NotificationServiceClient

type NotificationServiceClient interface {
	// 单条消息发送
	Send(ctx context.Context, in *SendRequest, opts ...grpc.CallOption) (*SendResponse, error)
	// 单条消息异步发送
	AsyncSend(ctx context.Context, in *AsyncSendRequest, opts ...grpc.CallOption) (*AsyncSendResponse, error)
	// 批量消息发送
	BatchSend(ctx context.Context, in *BatchSendRequest, opts ...grpc.CallOption) (*BatchSendResponse, error)
	// 批量消息异步发送
	AsyncBatchSend(ctx context.Context, in *AsyncBatchSendRequest, opts ...grpc.CallOption) (*AsyncBatchSendResponse, error)
}

NotificationServiceClient is the client API for NotificationService 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.

消息发送服务

type NotificationServiceServer

type NotificationServiceServer interface {
	// 单条消息发送
	Send(context.Context, *SendRequest) (*SendResponse, error)
	// 单条消息异步发送
	AsyncSend(context.Context, *AsyncSendRequest) (*AsyncSendResponse, error)
	// 批量消息发送
	BatchSend(context.Context, *BatchSendRequest) (*BatchSendResponse, error)
	// 批量消息异步发送
	AsyncBatchSend(context.Context, *AsyncBatchSendRequest) (*AsyncBatchSendResponse, error)
}

NotificationServiceServer is the server API for NotificationService service. All implementations should embed UnimplementedNotificationServiceServer for forward compatibility.

消息发送服务

type NotificationValidationError

type NotificationValidationError struct {
	// contains filtered or unexported fields
}

NotificationValidationError is the validation error returned by Notification.Validate if the designated constraints aren't met.

func (NotificationValidationError) Cause

Cause function returns cause value.

func (NotificationValidationError) Error

Error satisfies the builtin error interface

func (NotificationValidationError) ErrorName

func (e NotificationValidationError) ErrorName() string

ErrorName returns error name.

func (NotificationValidationError) Field

Field function returns field value.

func (NotificationValidationError) Key

Key function returns key value.

func (NotificationValidationError) Reason

Reason function returns reason value.

type ScheduledStrategy

type ScheduledStrategy struct {
	SendTime *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=send_time,json=sendTime,proto3" json:"send_time,omitempty"`
	// contains filtered or unexported fields
}

发送策略 - 调度发送

func (*ScheduledStrategy) Descriptor deprecated

func (*ScheduledStrategy) Descriptor() ([]byte, []int)

Deprecated: Use ScheduledStrategy.ProtoReflect.Descriptor instead.

func (*ScheduledStrategy) GetSendTime

func (x *ScheduledStrategy) GetSendTime() *timestamppb.Timestamp

func (*ScheduledStrategy) ProtoMessage

func (*ScheduledStrategy) ProtoMessage()

func (*ScheduledStrategy) ProtoReflect

func (x *ScheduledStrategy) ProtoReflect() protoreflect.Message

func (*ScheduledStrategy) Reset

func (x *ScheduledStrategy) Reset()

func (*ScheduledStrategy) String

func (x *ScheduledStrategy) String() string

func (*ScheduledStrategy) Validate

func (m *ScheduledStrategy) Validate() error

Validate checks the field values on ScheduledStrategy 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 (*ScheduledStrategy) ValidateAll

func (m *ScheduledStrategy) ValidateAll() error

ValidateAll checks the field values on ScheduledStrategy 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 ScheduledStrategyMultiError, or nil if none found.

type ScheduledStrategyMultiError

type ScheduledStrategyMultiError []error

ScheduledStrategyMultiError is an error wrapping multiple validation errors returned by ScheduledStrategy.ValidateAll() if the designated constraints aren't met.

func (ScheduledStrategyMultiError) AllErrors

func (m ScheduledStrategyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ScheduledStrategyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type ScheduledStrategyValidationError

type ScheduledStrategyValidationError struct {
	// contains filtered or unexported fields
}

ScheduledStrategyValidationError is the validation error returned by ScheduledStrategy.Validate if the designated constraints aren't met.

func (ScheduledStrategyValidationError) Cause

Cause function returns cause value.

func (ScheduledStrategyValidationError) Error

Error satisfies the builtin error interface

func (ScheduledStrategyValidationError) ErrorName

ErrorName returns error name.

func (ScheduledStrategyValidationError) Field

Field function returns field value.

func (ScheduledStrategyValidationError) Key

Key function returns key value.

func (ScheduledStrategyValidationError) Reason

Reason function returns reason value.

type SendRequest

type SendRequest struct {
	Notification *Notification `protobuf:"bytes,1,opt,name=notification,proto3" json:"notification,omitempty"`
	// contains filtered or unexported fields
}

单条消息发送请求

func (*SendRequest) Descriptor deprecated

func (*SendRequest) Descriptor() ([]byte, []int)

Deprecated: Use SendRequest.ProtoReflect.Descriptor instead.

func (*SendRequest) GetNotification

func (x *SendRequest) GetNotification() *Notification

func (*SendRequest) ProtoMessage

func (*SendRequest) ProtoMessage()

func (*SendRequest) ProtoReflect

func (x *SendRequest) ProtoReflect() protoreflect.Message

func (*SendRequest) Reset

func (x *SendRequest) Reset()

func (*SendRequest) String

func (x *SendRequest) String() string

func (*SendRequest) Validate

func (m *SendRequest) Validate() error

Validate checks the field values on SendRequest 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 (*SendRequest) ValidateAll

func (m *SendRequest) ValidateAll() error

ValidateAll checks the field values on SendRequest 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 SendRequestMultiError, or nil if none found.

type SendRequestMultiError

type SendRequestMultiError []error

SendRequestMultiError is an error wrapping multiple validation errors returned by SendRequest.ValidateAll() if the designated constraints aren't met.

func (SendRequestMultiError) AllErrors

func (m SendRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SendRequestMultiError) Error

func (m SendRequestMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type SendRequestValidationError

type SendRequestValidationError struct {
	// contains filtered or unexported fields
}

SendRequestValidationError is the validation error returned by SendRequest.Validate if the designated constraints aren't met.

func (SendRequestValidationError) Cause

Cause function returns cause value.

func (SendRequestValidationError) Error

Error satisfies the builtin error interface

func (SendRequestValidationError) ErrorName

func (e SendRequestValidationError) ErrorName() string

ErrorName returns error name.

func (SendRequestValidationError) Field

Field function returns field value.

func (SendRequestValidationError) Key

Key function returns key value.

func (SendRequestValidationError) Reason

Reason function returns reason value.

type SendResponse

type SendResponse struct {
	Result *SendResult `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"`
	// contains filtered or unexported fields
}

单条消息发送响应

func (*SendResponse) Descriptor deprecated

func (*SendResponse) Descriptor() ([]byte, []int)

Deprecated: Use SendResponse.ProtoReflect.Descriptor instead.

func (*SendResponse) GetResult

func (x *SendResponse) GetResult() *SendResult

func (*SendResponse) ProtoMessage

func (*SendResponse) ProtoMessage()

func (*SendResponse) ProtoReflect

func (x *SendResponse) ProtoReflect() protoreflect.Message

func (*SendResponse) Reset

func (x *SendResponse) Reset()

func (*SendResponse) String

func (x *SendResponse) String() string

func (*SendResponse) Validate

func (m *SendResponse) Validate() error

Validate checks the field values on SendResponse 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 (*SendResponse) ValidateAll

func (m *SendResponse) ValidateAll() error

ValidateAll checks the field values on SendResponse 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 SendResponseMultiError, or nil if none found.

type SendResponseMultiError

type SendResponseMultiError []error

SendResponseMultiError is an error wrapping multiple validation errors returned by SendResponse.ValidateAll() if the designated constraints aren't met.

func (SendResponseMultiError) AllErrors

func (m SendResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SendResponseMultiError) Error

func (m SendResponseMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type SendResponseValidationError

type SendResponseValidationError struct {
	// contains filtered or unexported fields
}

SendResponseValidationError is the validation error returned by SendResponse.Validate if the designated constraints aren't met.

func (SendResponseValidationError) Cause

Cause function returns cause value.

func (SendResponseValidationError) Error

Error satisfies the builtin error interface

func (SendResponseValidationError) ErrorName

func (e SendResponseValidationError) ErrorName() string

ErrorName returns error name.

func (SendResponseValidationError) Field

Field function returns field value.

func (SendResponseValidationError) Key

Key function returns key value.

func (SendResponseValidationError) Reason

Reason function returns reason value.

type SendResult

type SendResult struct {
	NotificationId string     `protobuf:"bytes,1,opt,name=notification_id,json=notificationId,proto3" json:"notification_id,omitempty"`
	Status         SendStatus `protobuf:"varint,2,opt,name=status,proto3,enum=notification.v1.SendStatus" json:"status,omitempty"`
	ErrCode        v1.ErrCode `protobuf:"varint,3,opt,name=err_code,json=errCode,proto3,enum=common.v1.ErrCode" json:"err_code,omitempty"`
	ErrMsg         string     `protobuf:"bytes,4,opt,name=err_msg,json=errMsg,proto3" json:"err_msg,omitempty"`
	// contains filtered or unexported fields
}

发送结果,包含消息 id 以及发送状态和错误信息

func (*SendResult) Descriptor deprecated

func (*SendResult) Descriptor() ([]byte, []int)

Deprecated: Use SendResult.ProtoReflect.Descriptor instead.

func (*SendResult) GetErrCode

func (x *SendResult) GetErrCode() v1.ErrCode

func (*SendResult) GetErrMsg

func (x *SendResult) GetErrMsg() string

func (*SendResult) GetNotificationId

func (x *SendResult) GetNotificationId() string

func (*SendResult) GetStatus

func (x *SendResult) GetStatus() SendStatus

func (*SendResult) ProtoMessage

func (*SendResult) ProtoMessage()

func (*SendResult) ProtoReflect

func (x *SendResult) ProtoReflect() protoreflect.Message

func (*SendResult) Reset

func (x *SendResult) Reset()

func (*SendResult) String

func (x *SendResult) String() string

func (*SendResult) Validate

func (m *SendResult) Validate() error

Validate checks the field values on SendResult 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 (*SendResult) ValidateAll

func (m *SendResult) ValidateAll() error

ValidateAll checks the field values on SendResult 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 SendResultMultiError, or nil if none found.

type SendResultMultiError

type SendResultMultiError []error

SendResultMultiError is an error wrapping multiple validation errors returned by SendResult.ValidateAll() if the designated constraints aren't met.

func (SendResultMultiError) AllErrors

func (m SendResultMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SendResultMultiError) Error

func (m SendResultMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type SendResultValidationError

type SendResultValidationError struct {
	// contains filtered or unexported fields
}

SendResultValidationError is the validation error returned by SendResult.Validate if the designated constraints aren't met.

func (SendResultValidationError) Cause

func (e SendResultValidationError) Cause() error

Cause function returns cause value.

func (SendResultValidationError) Error

Error satisfies the builtin error interface

func (SendResultValidationError) ErrorName

func (e SendResultValidationError) ErrorName() string

ErrorName returns error name.

func (SendResultValidationError) Field

Field function returns field value.

func (SendResultValidationError) Key

Key function returns key value.

func (SendResultValidationError) Reason

func (e SendResultValidationError) Reason() string

Reason function returns reason value.

type SendStatus

type SendStatus int32

发送状态

|-- PREPARE  - 准备中
|-- PENDING  - 挂起
|-- SUCCESS  - 成功
|-- FAILURE  - 失败
|-- CANCELED - 已取消
const (
	SendStatus_STATUS_UNSPECIFIED SendStatus = 0
	SendStatus_PREPARE            SendStatus = 1
	SendStatus_PENDING            SendStatus = 2
	SendStatus_SUCCESS            SendStatus = 3
	SendStatus_FAILURE            SendStatus = 4
	SendStatus_CANCEL             SendStatus = 5
)

func (SendStatus) Descriptor

func (SendStatus) Descriptor() protoreflect.EnumDescriptor

func (SendStatus) Enum

func (x SendStatus) Enum() *SendStatus

func (SendStatus) EnumDescriptor deprecated

func (SendStatus) EnumDescriptor() ([]byte, []int)

Deprecated: Use SendStatus.Descriptor instead.

func (SendStatus) Number

func (x SendStatus) Number() protoreflect.EnumNumber

func (SendStatus) String

func (x SendStatus) String() string

func (SendStatus) Type

type SendStrategy

type SendStrategy struct {

	// Types that are valid to be assigned to StrategyType:
	//
	//	*SendStrategy_Immediate
	//	*SendStrategy_Delayed
	//	*SendStrategy_Scheduled
	//	*SendStrategy_TimeWindow
	//	*SendStrategy_Deadline
	StrategyType isSendStrategy_StrategyType `protobuf_oneof:"strategy_type"`
	// contains filtered or unexported fields
}

发送策略

func (*SendStrategy) Descriptor deprecated

func (*SendStrategy) Descriptor() ([]byte, []int)

Deprecated: Use SendStrategy.ProtoReflect.Descriptor instead.

func (*SendStrategy) GetDeadline

func (x *SendStrategy) GetDeadline() *DeadlineStrategy

func (*SendStrategy) GetDelayed

func (x *SendStrategy) GetDelayed() *DelayedStrategy

func (*SendStrategy) GetImmediate

func (x *SendStrategy) GetImmediate() *ImmediatelyStrategy

func (*SendStrategy) GetScheduled

func (x *SendStrategy) GetScheduled() *ScheduledStrategy

func (*SendStrategy) GetStrategyType

func (x *SendStrategy) GetStrategyType() isSendStrategy_StrategyType

func (*SendStrategy) GetTimeWindow

func (x *SendStrategy) GetTimeWindow() *TimeWindowStrategy

func (*SendStrategy) ProtoMessage

func (*SendStrategy) ProtoMessage()

func (*SendStrategy) ProtoReflect

func (x *SendStrategy) ProtoReflect() protoreflect.Message

func (*SendStrategy) Reset

func (x *SendStrategy) Reset()

func (*SendStrategy) String

func (x *SendStrategy) String() string

func (*SendStrategy) Validate

func (m *SendStrategy) Validate() error

Validate checks the field values on SendStrategy 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 (*SendStrategy) ValidateAll

func (m *SendStrategy) ValidateAll() error

ValidateAll checks the field values on SendStrategy 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 SendStrategyMultiError, or nil if none found.

type SendStrategyMultiError

type SendStrategyMultiError []error

SendStrategyMultiError is an error wrapping multiple validation errors returned by SendStrategy.ValidateAll() if the designated constraints aren't met.

func (SendStrategyMultiError) AllErrors

func (m SendStrategyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SendStrategyMultiError) Error

func (m SendStrategyMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type SendStrategyValidationError

type SendStrategyValidationError struct {
	// contains filtered or unexported fields
}

SendStrategyValidationError is the validation error returned by SendStrategy.Validate if the designated constraints aren't met.

func (SendStrategyValidationError) Cause

Cause function returns cause value.

func (SendStrategyValidationError) Error

Error satisfies the builtin error interface

func (SendStrategyValidationError) ErrorName

func (e SendStrategyValidationError) ErrorName() string

ErrorName returns error name.

func (SendStrategyValidationError) Field

Field function returns field value.

func (SendStrategyValidationError) Key

Key function returns key value.

func (SendStrategyValidationError) Reason

Reason function returns reason value.

type SendStrategy_Deadline

type SendStrategy_Deadline struct {
	Deadline *DeadlineStrategy `protobuf:"bytes,5,opt,name=deadline,proto3,oneof"`
}

type SendStrategy_Delayed

type SendStrategy_Delayed struct {
	Delayed *DelayedStrategy `protobuf:"bytes,2,opt,name=delayed,proto3,oneof"`
}

type SendStrategy_Immediate

type SendStrategy_Immediate struct {
	Immediate *ImmediatelyStrategy `protobuf:"bytes,1,opt,name=immediate,proto3,oneof"`
}

type SendStrategy_Scheduled

type SendStrategy_Scheduled struct {
	Scheduled *ScheduledStrategy `protobuf:"bytes,3,opt,name=scheduled,proto3,oneof"`
}

type SendStrategy_TimeWindow

type SendStrategy_TimeWindow struct {
	TimeWindow *TimeWindowStrategy `protobuf:"bytes,4,opt,name=time_window,json=timeWindow,proto3,oneof"`
}

type TimeWindowStrategy

type TimeWindowStrategy struct {
	StartTimeMillis int64 `protobuf:"varint,1,opt,name=start_time_millis,json=startTimeMillis,proto3" json:"start_time_millis,omitempty"`
	EndTimeMillis   int64 `protobuf:"varint,2,opt,name=end_time_millis,json=endTimeMillis,proto3" json:"end_time_millis,omitempty"`
	// contains filtered or unexported fields
}

发送策略 - 时间窗口内发送

func (*TimeWindowStrategy) Descriptor deprecated

func (*TimeWindowStrategy) Descriptor() ([]byte, []int)

Deprecated: Use TimeWindowStrategy.ProtoReflect.Descriptor instead.

func (*TimeWindowStrategy) GetEndTimeMillis

func (x *TimeWindowStrategy) GetEndTimeMillis() int64

func (*TimeWindowStrategy) GetStartTimeMillis

func (x *TimeWindowStrategy) GetStartTimeMillis() int64

func (*TimeWindowStrategy) ProtoMessage

func (*TimeWindowStrategy) ProtoMessage()

func (*TimeWindowStrategy) ProtoReflect

func (x *TimeWindowStrategy) ProtoReflect() protoreflect.Message

func (*TimeWindowStrategy) Reset

func (x *TimeWindowStrategy) Reset()

func (*TimeWindowStrategy) String

func (x *TimeWindowStrategy) String() string

func (*TimeWindowStrategy) Validate

func (m *TimeWindowStrategy) Validate() error

Validate checks the field values on TimeWindowStrategy 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 (*TimeWindowStrategy) ValidateAll

func (m *TimeWindowStrategy) ValidateAll() error

ValidateAll checks the field values on TimeWindowStrategy 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 TimeWindowStrategyMultiError, or nil if none found.

type TimeWindowStrategyMultiError

type TimeWindowStrategyMultiError []error

TimeWindowStrategyMultiError is an error wrapping multiple validation errors returned by TimeWindowStrategy.ValidateAll() if the designated constraints aren't met.

func (TimeWindowStrategyMultiError) AllErrors

func (m TimeWindowStrategyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (TimeWindowStrategyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type TimeWindowStrategyValidationError

type TimeWindowStrategyValidationError struct {
	// contains filtered or unexported fields
}

TimeWindowStrategyValidationError is the validation error returned by TimeWindowStrategy.Validate if the designated constraints aren't met.

func (TimeWindowStrategyValidationError) Cause

Cause function returns cause value.

func (TimeWindowStrategyValidationError) Error

Error satisfies the builtin error interface

func (TimeWindowStrategyValidationError) ErrorName

ErrorName returns error name.

func (TimeWindowStrategyValidationError) Field

Field function returns field value.

func (TimeWindowStrategyValidationError) Key

Key function returns key value.

func (TimeWindowStrategyValidationError) Reason

Reason function returns reason value.

type UnimplementedNotificationServiceServer

type UnimplementedNotificationServiceServer struct{}

UnimplementedNotificationServiceServer should 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 (UnimplementedNotificationServiceServer) AsyncBatchSend

func (UnimplementedNotificationServiceServer) AsyncSend

func (UnimplementedNotificationServiceServer) BatchSend

func (UnimplementedNotificationServiceServer) Send

type UnsafeNotificationServiceServer

type UnsafeNotificationServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeNotificationServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to NotificationServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL