Documentation
¶
Index ¶
- Variables
- type Data
- func (*Data) Descriptor() ([]byte, []int)deprecated
- func (x *Data) GetCausedBy() *users.UserShort
- func (x *Data) GetLink() *Link
- func (*Data) ProtoMessage()
- func (x *Data) ProtoReflect() protoreflect.Message
- func (x *Data) Reset()
- func (x *Data) Scan(value any) error
- func (x *Data) String() string
- func (m *Data) Validate() error
- func (m *Data) ValidateAll() error
- func (x *Data) Value() (driver.Value, error)
- type DataMultiError
- type DataValidationError
- type Link
- func (*Link) Descriptor() ([]byte, []int)deprecated
- func (x *Link) GetExternal() bool
- func (x *Link) GetTitle() string
- func (x *Link) GetTo() string
- func (*Link) ProtoMessage()
- func (x *Link) ProtoReflect() protoreflect.Message
- func (x *Link) Reset()
- func (x *Link) String() string
- func (m *Link) Validate() error
- func (m *Link) ValidateAll() error
- type LinkMultiError
- type LinkValidationError
- type Notification
- func (*Notification) Descriptor() ([]byte, []int)deprecated
- func (x *Notification) GetCategory() NotificationCategory
- func (x *Notification) GetContent() *common.TranslateItem
- func (x *Notification) GetCreatedAt() *timestamp.Timestamp
- func (x *Notification) GetData() *Data
- func (x *Notification) GetId() uint64
- func (x *Notification) GetReadAt() *timestamp.Timestamp
- func (x *Notification) GetStarred() bool
- func (x *Notification) GetTitle() *common.TranslateItem
- func (x *Notification) GetType() string
- func (x *Notification) GetUserId() int32
- func (*Notification) ProtoMessage()
- func (x *Notification) ProtoReflect() protoreflect.Message
- func (x *Notification) Reset()
- func (x *Notification) String() string
- func (m *Notification) Validate() error
- func (m *Notification) ValidateAll() error
- type NotificationCategory
- func (NotificationCategory) Descriptor() protoreflect.EnumDescriptor
- func (x NotificationCategory) Enum() *NotificationCategory
- func (NotificationCategory) EnumDescriptor() ([]byte, []int)deprecated
- func (x NotificationCategory) Number() protoreflect.EnumNumber
- func (x NotificationCategory) String() string
- func (NotificationCategory) Type() protoreflect.EnumType
- type NotificationMultiError
- type NotificationValidationError
- func (e NotificationValidationError) Cause() error
- func (e NotificationValidationError) Error() string
- func (e NotificationValidationError) ErrorName() string
- func (e NotificationValidationError) Field() string
- func (e NotificationValidationError) Key() bool
- func (e NotificationValidationError) Reason() string
Constants ¶
This section is empty.
Variables ¶
var ( NotificationCategory_name = map[int32]string{ 0: "NOTIFICATION_CATEGORY_UNSPECIFIED", 1: "NOTIFICATION_CATEGORY_GENERAL", 2: "NOTIFICATION_CATEGORY_DOCUMENT", } NotificationCategory_value = map[string]int32{ "NOTIFICATION_CATEGORY_UNSPECIFIED": 0, "NOTIFICATION_CATEGORY_GENERAL": 1, "NOTIFICATION_CATEGORY_DOCUMENT": 2, } )
Enum value maps for NotificationCategory.
var File_resources_notifications_notifications_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Data ¶ added in v0.6.0
type Data struct { Link *Link `protobuf:"bytes,1,opt,name=link,proto3,oneof" json:"link,omitempty"` CausedBy *users.UserShort `protobuf:"bytes,2,opt,name=caused_by,json=causedBy,proto3,oneof" json:"caused_by,omitempty"` // contains filtered or unexported fields }
func (*Data) Descriptor
deprecated
added in
v0.6.0
func (*Data) GetCausedBy ¶ added in v0.6.0
func (*Data) ProtoMessage ¶ added in v0.6.0
func (*Data) ProtoMessage()
func (*Data) ProtoReflect ¶ added in v0.6.0
func (x *Data) ProtoReflect() protoreflect.Message
func (*Data) Validate ¶ added in v0.6.0
Validate checks the field values on Data 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 (*Data) ValidateAll ¶ added in v0.6.0
ValidateAll checks the field values on Data 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 DataMultiError, or nil if none found.
type DataMultiError ¶ added in v0.6.0
type DataMultiError []error
DataMultiError is an error wrapping multiple validation errors returned by Data.ValidateAll() if the designated constraints aren't met.
func (DataMultiError) AllErrors ¶ added in v0.6.0
func (m DataMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (DataMultiError) Error ¶ added in v0.6.0
func (m DataMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type DataValidationError ¶ added in v0.6.0
type DataValidationError struct {
// contains filtered or unexported fields
}
DataValidationError is the validation error returned by Data.Validate if the designated constraints aren't met.
func (DataValidationError) Cause ¶ added in v0.6.0
func (e DataValidationError) Cause() error
Cause function returns cause value.
func (DataValidationError) Error ¶ added in v0.6.0
func (e DataValidationError) Error() string
Error satisfies the builtin error interface
func (DataValidationError) ErrorName ¶ added in v0.6.0
func (e DataValidationError) ErrorName() string
ErrorName returns error name.
func (DataValidationError) Field ¶ added in v0.6.0
func (e DataValidationError) Field() string
Field function returns field value.
func (DataValidationError) Key ¶ added in v0.6.0
func (e DataValidationError) Key() bool
Key function returns key value.
func (DataValidationError) Reason ¶ added in v0.6.0
func (e DataValidationError) Reason() string
Reason function returns reason value.
type Link ¶ added in v0.6.0
type Link struct { To string `protobuf:"bytes,1,opt,name=to,proto3" json:"to,omitempty"` Title *string `protobuf:"bytes,2,opt,name=title,proto3,oneof" json:"title,omitempty"` External *bool `protobuf:"varint,3,opt,name=external,proto3,oneof" json:"external,omitempty"` // contains filtered or unexported fields }
func (*Link) Descriptor
deprecated
added in
v0.6.0
func (*Link) GetExternal ¶ added in v0.6.0
func (*Link) ProtoMessage ¶ added in v0.6.0
func (*Link) ProtoMessage()
func (*Link) ProtoReflect ¶ added in v0.6.0
func (x *Link) ProtoReflect() protoreflect.Message
func (*Link) Validate ¶ added in v0.6.0
Validate checks the field values on Link 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 (*Link) ValidateAll ¶ added in v0.6.0
ValidateAll checks the field values on Link 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 LinkMultiError, or nil if none found.
type LinkMultiError ¶ added in v0.6.0
type LinkMultiError []error
LinkMultiError is an error wrapping multiple validation errors returned by Link.ValidateAll() if the designated constraints aren't met.
func (LinkMultiError) AllErrors ¶ added in v0.6.0
func (m LinkMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (LinkMultiError) Error ¶ added in v0.6.0
func (m LinkMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type LinkValidationError ¶ added in v0.6.0
type LinkValidationError struct {
// contains filtered or unexported fields
}
LinkValidationError is the validation error returned by Link.Validate if the designated constraints aren't met.
func (LinkValidationError) Cause ¶ added in v0.6.0
func (e LinkValidationError) Cause() error
Cause function returns cause value.
func (LinkValidationError) Error ¶ added in v0.6.0
func (e LinkValidationError) Error() string
Error satisfies the builtin error interface
func (LinkValidationError) ErrorName ¶ added in v0.6.0
func (e LinkValidationError) ErrorName() string
ErrorName returns error name.
func (LinkValidationError) Field ¶ added in v0.6.0
func (e LinkValidationError) Field() string
Field function returns field value.
func (LinkValidationError) Key ¶ added in v0.6.0
func (e LinkValidationError) Key() bool
Key function returns key value.
func (LinkValidationError) Reason ¶ added in v0.6.0
func (e LinkValidationError) Reason() string
Reason function returns reason value.
type Notification ¶
type Notification struct { Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` CreatedAt *timestamp.Timestamp `protobuf:"bytes,2,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` ReadAt *timestamp.Timestamp `protobuf:"bytes,3,opt,name=read_at,json=readAt,proto3" json:"read_at,omitempty"` UserId int32 `protobuf:"varint,4,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` // @sanitize Title *common.TranslateItem `protobuf:"bytes,5,opt,name=title,proto3" json:"title,omitempty"` Type *string `protobuf:"bytes,6,opt,name=type,proto3,oneof" json:"type,omitempty"` // @sanitize Content *common.TranslateItem `protobuf:"bytes,7,opt,name=content,proto3" json:"content,omitempty"` Category NotificationCategory `protobuf:"varint,8,opt,name=category,proto3,enum=resources.notifications.NotificationCategory" json:"category,omitempty"` Data *Data `protobuf:"bytes,9,opt,name=data,proto3,oneof" json:"data,omitempty"` Starred *bool `protobuf:"varint,10,opt,name=starred,proto3,oneof" json:"starred,omitempty"` // contains filtered or unexported fields }
func (*Notification) Descriptor
deprecated
func (*Notification) Descriptor() ([]byte, []int)
Deprecated: Use Notification.ProtoReflect.Descriptor instead.
func (*Notification) GetCategory ¶ added in v0.6.0
func (x *Notification) GetCategory() NotificationCategory
func (*Notification) GetContent ¶
func (x *Notification) GetContent() *common.TranslateItem
func (*Notification) GetCreatedAt ¶
func (x *Notification) GetCreatedAt() *timestamp.Timestamp
func (*Notification) GetData ¶
func (x *Notification) GetData() *Data
func (*Notification) GetId ¶
func (x *Notification) GetId() uint64
func (*Notification) GetReadAt ¶
func (x *Notification) GetReadAt() *timestamp.Timestamp
func (*Notification) GetStarred ¶ added in v0.8.10
func (x *Notification) GetStarred() bool
func (*Notification) GetTitle ¶
func (x *Notification) GetTitle() *common.TranslateItem
func (*Notification) GetType ¶
func (x *Notification) GetType() string
func (*Notification) GetUserId ¶
func (x *Notification) GetUserId() int32
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 NotificationCategory ¶ added in v0.8.3
type NotificationCategory int32
const ( NotificationCategory_NOTIFICATION_CATEGORY_UNSPECIFIED NotificationCategory = 0 NotificationCategory_NOTIFICATION_CATEGORY_GENERAL NotificationCategory = 1 NotificationCategory_NOTIFICATION_CATEGORY_DOCUMENT NotificationCategory = 2 )
func (NotificationCategory) Descriptor ¶ added in v0.8.3
func (NotificationCategory) Descriptor() protoreflect.EnumDescriptor
func (NotificationCategory) Enum ¶ added in v0.8.3
func (x NotificationCategory) Enum() *NotificationCategory
func (NotificationCategory) EnumDescriptor
deprecated
added in
v0.8.3
func (NotificationCategory) EnumDescriptor() ([]byte, []int)
Deprecated: Use NotificationCategory.Descriptor instead.
func (NotificationCategory) Number ¶ added in v0.8.3
func (x NotificationCategory) Number() protoreflect.EnumNumber
func (NotificationCategory) String ¶ added in v0.8.3
func (x NotificationCategory) String() string
func (NotificationCategory) Type ¶ added in v0.8.3
func (NotificationCategory) Type() protoreflect.EnumType
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 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 ¶
func (e NotificationValidationError) Cause() error
Cause function returns cause value.
func (NotificationValidationError) Error ¶
func (e NotificationValidationError) Error() string
Error satisfies the builtin error interface
func (NotificationValidationError) ErrorName ¶
func (e NotificationValidationError) ErrorName() string
ErrorName returns error name.
func (NotificationValidationError) Field ¶
func (e NotificationValidationError) Field() string
Field function returns field value.
func (NotificationValidationError) Key ¶
func (e NotificationValidationError) Key() bool
Key function returns key value.
func (NotificationValidationError) Reason ¶
func (e NotificationValidationError) Reason() string
Reason function returns reason value.