pub struct ForumSearchHit {
pub type: String,
pub topic_id: i64,
pub topic_slug: Option<String>,
pub post_id: Option<i64>,
pub author_id: i64,
pub author_username: String,
pub title: String,
pub body: String,
pub snippet: Option<String>,
pub category_slug: String,
pub category_title: String,
pub created_at: String,
}Expand description
A forum search hit (GET /api/forum/search result).
Fields§
§type: Stringtopic (OP match) or post (reply match).
topic_id: i64Topic id the hit belongs to.
topic_slug: Option<String>Topic slug, when assigned.
post_id: Option<i64>Post id, when the hit is a reply.
Author user id.
Author display name.
title: StringTopic title.
body: StringMatched body text.
snippet: Option<String><mark>-highlighted snippet, when present.
category_slug: StringCategory slug.
category_title: StringCategory display title.
created_at: StringISO timestamp of the matching post/topic.
Trait Implementations§
Source§impl Clone for ForumSearchHit
impl Clone for ForumSearchHit
Source§fn clone(&self) -> ForumSearchHit
fn clone(&self) -> ForumSearchHit
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 ForumSearchHit
impl Debug for ForumSearchHit
Source§impl<'de> Deserialize<'de> for ForumSearchHit
impl<'de> Deserialize<'de> for ForumSearchHit
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 ForumSearchHit
impl RefUnwindSafe for ForumSearchHit
impl Send for ForumSearchHit
impl Sync for ForumSearchHit
impl Unpin for ForumSearchHit
impl UnsafeUnpin for ForumSearchHit
impl UnwindSafe for ForumSearchHit
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
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<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
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> ⓘ
Converts
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> ⓘ
Converts
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 more