pub enum RelationKind {
Blocks,
BlockedBy,
Duplicates,
Related,
}Expand description
The closed vocabulary of typed relations.
Exactly four kinds ship in this mission (decision
01M3BXC5P4MK0BYECA3K1B9Z82). The set is compiled in — there is no
configuration key — and an unknown kind is rejected rather than coerced.
Variants§
Blocks
The source issue blocks the target issue. The canonical stored form of a blocking relationship.
BlockedBy
The source issue is blocked by the target issue. An input spelling
only: it normalizes into the equivalent RelationKind::Blocks edge
and is never persisted.
Duplicates
The source issue duplicates the target issue. No blocked-state effect.
Related
Explicit non-directional association. Stored once, never mirrored, and the only non-directional kind.
Implementations§
Source§impl RelationKind
impl RelationKind
Sourcepub const ALL: [RelationKind; 4]
pub const ALL: [RelationKind; 4]
Every kind in the closed vocabulary, in canonical spell order.
Sourcepub fn as_str(self) -> &'static str
pub fn as_str(self) -> &'static str
The canonical lowercase spelling used in files and CLI output.
Sourcepub fn is_directional(self) -> bool
pub fn is_directional(self) -> bool
Whether the kind has a direction. False only for RelationKind::Related.
Trait Implementations§
Source§impl Clone for RelationKind
impl Clone for RelationKind
impl Copy for RelationKind
Source§impl Debug for RelationKind
impl Debug for RelationKind
Source§impl<'de> Deserialize<'de> for RelationKind
impl<'de> Deserialize<'de> for RelationKind
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Display for RelationKind
impl Display for RelationKind
impl Eq for RelationKind
Source§impl FromStr for RelationKind
impl FromStr for RelationKind
Source§fn from_str(s: &str) -> Result<Self, Self::Err>
fn from_str(s: &str) -> Result<Self, Self::Err>
Parse a canonical kind spelling, rejecting anything outside the closed
vocabulary with an DiagnosticKind::UnknownKind diagnostic. An
unknown kind is never coerced to related.
Source§type Err = Diagnostic
type Err = Diagnostic
Source§impl Hash for RelationKind
impl Hash for RelationKind
Source§impl Ord for RelationKind
impl Ord for RelationKind
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for RelationKind
impl PartialEq for RelationKind
Source§impl PartialOrd for RelationKind
impl PartialOrd for RelationKind
Source§impl Serialize for RelationKind
impl Serialize for RelationKind
impl StructuralPartialEq for RelationKind
Auto Trait Implementations§
impl Freeze for RelationKind
impl RefUnwindSafe for RelationKind
impl Send for RelationKind
impl Sync for RelationKind
impl Unpin for RelationKind
impl UnsafeUnpin for RelationKind
impl UnwindSafe for RelationKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> ToCompactString for Twhere
T: Display,
impl<T> ToCompactString for Twhere
T: Display,
Source§fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
ToCompactString::to_compact_string() Read moreSource§fn to_compact_string(&self) -> CompactString
fn to_compact_string(&self) -> CompactString
CompactString. Read more