pub struct CommentChainResponse {
pub post_id: PostId,
pub post_title: Option<String>,
pub root: Option<PostResponse>,
pub omitted_ancestors: u64,
pub chain: Vec<CommentResponse>,
}Expand description
A comment with its ancestor chain up to the root.
Fields§
§post_id: PostId§post_title: Option<String>§root: Option<PostResponse>The root post of the thread, body included. Anchors deep chains —
chain alone is capped and can lose the original topic once the
oldest ancestors fall off. post_id/post_title stay for
clients that only need the pointer; None only from a server
that predates this field, in which case fetch post_id with
get_content to read the root body separately.
omitted_ancestors: u64How many ancestors closer to the root than chain covers were
dropped to keep the chain bounded. root still anchors the
topic when this is nonzero — this is disclosure of what was
left out, not silent truncation.
chain: Vec<CommentResponse>Comments ordered root-to-leaf (first entry is the oldest ancestor, last entry is the requested comment).
Trait Implementations§
Source§impl Debug for CommentChainResponse
impl Debug for CommentChainResponse
Source§impl<'de> Deserialize<'de> for CommentChainResponse
impl<'de> Deserialize<'de> for CommentChainResponse
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
Auto Trait Implementations§
impl Freeze for CommentChainResponse
impl RefUnwindSafe for CommentChainResponse
impl Send for CommentChainResponse
impl Sync for CommentChainResponse
impl Unpin for CommentChainResponse
impl UnsafeUnpin for CommentChainResponse
impl UnwindSafe for CommentChainResponse
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