pub struct OpenEpisode {
pub id: String,
pub last_sign_of_life: Option<String>,
pub stranded: Option<bool>,
}Expand description
An open episode in a work tree, as far as holding its work goes: it holds the work only
while stranded is Some(false); a stranded or unjudgeable one holds nothing.
use majordomus_cli::worktree::OpenEpisode;
let unjudged = OpenEpisode {
id: "s-20260101000000-0a0a".into(),
last_sign_of_life: None,
stranded: None,
};
let wire = serde_json::to_value(&unjudged).unwrap();
assert!(wire.get("stranded").is_none(), "what could not be judged is absent, not false");
let back: OpenEpisode = serde_json::from_value(wire).unwrap();
assert_eq!(back, unjudged);Fields§
§id: StringThe episode.
last_sign_of_life: Option<String>Its newest sign of life, RFC 3339 in UTC.
stranded: Option<bool>Silent longer than the threshold. Absent when that cannot be judged — no threshold, or no readable sign of life — and then it holds nothing.
Trait Implementations§
Source§impl Clone for OpenEpisode
impl Clone for OpenEpisode
Source§fn clone(&self) -> OpenEpisode
fn clone(&self) -> OpenEpisode
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for OpenEpisode
impl Debug for OpenEpisode
Source§impl<'de> Deserialize<'de> for OpenEpisode
impl<'de> Deserialize<'de> for OpenEpisode
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>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for OpenEpisode
Source§impl JsonSchema for OpenEpisode
impl JsonSchema for OpenEpisode
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for OpenEpisode
impl PartialEq for OpenEpisode
Source§fn eq(&self, other: &OpenEpisode) -> bool
fn eq(&self, other: &OpenEpisode) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for OpenEpisode
impl Serialize for OpenEpisode
impl StructuralPartialEq for OpenEpisode
Auto Trait Implementations§
impl Freeze for OpenEpisode
impl RefUnwindSafe for OpenEpisode
impl Send for OpenEpisode
impl Sync for OpenEpisode
impl Unpin for OpenEpisode
impl UnsafeUnpin for OpenEpisode
impl UnwindSafe for OpenEpisode
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
Mutably borrows from an owned value. Read more
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
Compare self to
key and return true if they are equal.