pub struct Comment<S: BosStr = DefaultStr> {
pub attachments: Option<Images<S>>,
pub body: S,
pub body_facets: Option<Vec<Facet<S>>>,
pub bug: AtUri<S>,
pub created_at: Datetime,
pub parent: Option<AtUri<S>>,
pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}Fields§
§attachments: Option<Images<S>>§body: S§body_facets: Option<Vec<Facet<S>>>Annotations of body text (mentions and links)
bug: AtUri<S>Reference to the bug report
created_at: Datetime§parent: Option<AtUri<S>>Optional reference to parent comment for threading
extra_data: Option<BTreeMap<SmolStr, Data<S>>>Implementations§
Source§impl Comment<DefaultStr>
impl Comment<DefaultStr>
Sourcepub fn new() -> CommentBuilder<Empty, DefaultStr>
pub fn new() -> CommentBuilder<Empty, DefaultStr>
Create a new builder for this type, using the default string type (DefaultStr = SmolStr) if needed
Trait Implementations§
Source§impl<S: BosStr> Collection for Comment<S>
impl<S: BosStr> Collection for Comment<S>
Source§const NSID: &'static str = "network.slices.tools.bug.comment"
const NSID: &'static str = "network.slices.tools.bug.comment"
The NSID for the Lexicon that defines the schema of records in this collection.
Source§type Record = CommentRecord
type Record = CommentRecord
A marker type implementing
XrpcResp that allows typed deserialization of records
from this collection. Used by AgentSessionExt::get_record to return properly typed responses.Source§impl<'de, S> Deserialize<'de> for Comment<S>where
S: Deserialize<'de> + BosStr,
impl<'de, S> Deserialize<'de> for Comment<S>where
S: Deserialize<'de> + BosStr,
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<S: Eq + BosStr> Eq for Comment<S>
Source§impl<S: BosStr> From<CommentGetRecordOutput<S>> for Comment<S>
impl<S: BosStr> From<CommentGetRecordOutput<S>> for Comment<S>
Source§fn from(output: CommentGetRecordOutput<S>) -> Self
fn from(output: CommentGetRecordOutput<S>) -> Self
Converts to this type from the input type.
Source§impl<S: BosStr + IntoStatic> IntoStatic for Comment<S>
impl<S: BosStr + IntoStatic> IntoStatic for Comment<S>
Source§impl<S: BosStr> LexiconSchema for Comment<S>
impl<S: BosStr> LexiconSchema for Comment<S>
Source§fn lexicon_doc() -> LexiconDoc<'static>
fn lexicon_doc() -> LexiconDoc<'static>
Generate the lexicon document for this type Read more
Source§fn validate(&self) -> Result<(), ConstraintError>
fn validate(&self) -> Result<(), ConstraintError>
Validate an instance against lexicon constraints Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether this type should be inlined vs referenced Read more
Source§impl<S: PartialEq + BosStr> PartialEq for Comment<S>
impl<S: PartialEq + BosStr> PartialEq for Comment<S>
impl<S: BosStr> StructuralPartialEq for Comment<S>
Auto Trait Implementations§
impl<S> Freeze for Comment<S>where
S: Freeze,
impl<S> RefUnwindSafe for Comment<S>where
S: RefUnwindSafe,
impl<S> Send for Comment<S>where
S: Send,
impl<S> Sync for Comment<S>where
S: Sync,
impl<S> Unpin for Comment<S>where
S: Unpin,
impl<S> UnsafeUnpin for Comment<S>where
S: UnsafeUnpin,
impl<S> UnwindSafe for Comment<S>where
S: UnwindSafe + RefUnwindSafe,
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>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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
Compare self to
key and return true if they are equal.