#[repr(i32)]pub enum NotificationKind {
Unspecified = 0,
ReviewReady = 1,
AgentCompleted = 2,
SecuritySurface = 3,
DriftAlert = 4,
RepoQuietDigest = 5,
ImportedDiscussion = 6,
Mention = 10,
DiscussionReply = 11,
AccountSecurity = 12,
SteerHeld = 13,
}Expand description
Kind of notification. Values 1..6 MIRROR attention.proto FeedItemKind’s numbers and names so a FeedItem projects onto a Notification without remapping; values 10..13 are notification-only kinds with no FeedItem counterpart. The 7..9 gap is reserved to keep future FeedItemKind additions number-aligned.
Variants§
Unspecified = 0
ReviewReady = 1
mirrors FEED_ITEM_KIND_REVIEW_READY
AgentCompleted = 2
mirrors FEED_ITEM_KIND_AGENT_COMPLETED
SecuritySurface = 3
mirrors FEED_ITEM_KIND_SECURITY_SURFACE
DriftAlert = 4
mirrors FEED_ITEM_KIND_DRIFT_ALERT
RepoQuietDigest = 5
mirrors FEED_ITEM_KIND_REPO_QUIET
ImportedDiscussion = 6
mirrors FEED_ITEM_KIND_IMPORTED_DISCUSSION
Mention = 10
an @mention resolved to the recipient
DiscussionReply = 11
a reply on a discussion the recipient joined
AccountSecurity = 12
account/credential security event
SteerHeld = 13
an agent steer is held awaiting the recipient
Implementations§
Source§impl NotificationKind
impl NotificationKind
Sourcepub const fn is_valid(value: i32) -> bool
pub const fn is_valid(value: i32) -> bool
Returns true if value is a variant of NotificationKind.
Sourcepub fn from_i32(value: i32) -> Option<NotificationKind>
👎Deprecated: Use the TryFrom<i32> implementation instead
pub fn from_i32(value: i32) -> Option<NotificationKind>
Use the TryFrom<i32> implementation instead
Converts an i32 to a NotificationKind, or None if value is not a valid variant.
Source§impl NotificationKind
impl NotificationKind
Sourcepub fn as_str_name(&self) -> &'static str
pub fn as_str_name(&self) -> &'static str
String value of the enum field names used in the ProtoBuf definition.
The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.
Sourcepub fn from_str_name(value: &str) -> Option<Self>
pub fn from_str_name(value: &str) -> Option<Self>
Creates an enum from field names used in the ProtoBuf definition.
Trait Implementations§
Source§impl Clone for NotificationKind
impl Clone for NotificationKind
Source§fn clone(&self) -> NotificationKind
fn clone(&self) -> NotificationKind
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more