pub struct Moment {Show 26 fields
pub id: String,
pub title: String,
pub short_title: Option<String>,
pub hook: String,
pub summary: String,
pub status: String,
pub severity: String,
pub frequency: String,
pub weight: u32,
pub featured: bool,
pub audiences: Vec<String>,
pub areas: Vec<String>,
pub lifecycle: Vec<String>,
pub tags: Vec<String>,
pub signals: Vec<Signal>,
pub examples: Vec<Example>,
pub commands: Vec<String>,
pub capabilities: Vec<String>,
pub claims: Vec<String>,
pub doctrines: Vec<String>,
pub use_cases: Vec<String>,
pub related: Vec<String>,
pub aliases: Vec<String>,
pub route: String,
pub source: String,
pub body: String,
/* private fields */
}Expand description
One operational moment, as its file declares it plus the two facts the file cannot hold: where it came from and where it is published.
Fields§
§id: StringThe identity, the slug and the file name.
title: StringThe moment as a heading.
short_title: Option<String>Two or three words for a narrow column, when the record carries one.
hook: StringThe first-person line an index shows.
summary: StringOne line: what is actually wrong.
status: Stringstable, draft or deprecated.
severity: Stringlow, medium or high.
frequency: Stringrare, occasional, common or constant.
weight: u32Presentation order, lowest first.
featured: boolWhether the homepage shows it.
audiences: Vec<String>The audiences that recognise it.
areas: Vec<String>The operational areas it falls under.
lifecycle: Vec<String>The stages of work at which it shows up.
Free tags.
signals: Vec<Signal>The observable symptoms.
examples: Vec<Example>The concrete situations.
commands: Vec<String>Commands of the tool that answer it.
capabilities: Vec<String>Capability ids of the executable that answer it.
claims: Vec<String>Claims that say what is guaranteed here.
doctrines: Vec<String>Rules of the effective set that govern it.
use_cases: Vec<String>Use cases that show the way out.
Moments explicitly related to this one. The reverse is derived.
aliases: Vec<String>Other words a reader might search for.
route: StringDerived: /why/<id>/. Never authored; the schema refuses a route key.
source: StringDerived: the repository-relative file the record came from.
body: StringThe Markdown body, without its front matter.
Implementations§
Source§impl Moment
impl Moment
Sourcepub fn search_text(&self) -> String
pub fn search_text(&self) -> String
The text a search reads: everything a reader might remember about this moment.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Moment
impl<'de> Deserialize<'de> for Moment
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>,
impl Eq for Moment
Source§impl JsonSchema for Moment
impl JsonSchema for Moment
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreimpl StructuralPartialEq for Moment
Auto Trait Implementations§
impl Freeze for Moment
impl RefUnwindSafe for Moment
impl Send for Moment
impl Sync for Moment
impl Unpin for Moment
impl UnsafeUnpin for Moment
impl UnwindSafe for Moment
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.