pub struct ThreadgateBuilder<St: State, S: BosStr = DefaultStr> { /* private fields */ }Expand description
Builder for constructing an instance of this type.
Implementations§
Source§impl<S: BosStr> ThreadgateBuilder<Empty, S>
impl<S: BosStr> ThreadgateBuilder<Empty, S>
Source§impl<St: State, S: BosStr> ThreadgateBuilder<St, S>
impl<St: State, S: BosStr> ThreadgateBuilder<St, S>
Sourcepub fn allow(
self,
value: impl Into<Option<Vec<ThreadgateAllowItem<S>>>>,
) -> Self
pub fn allow( self, value: impl Into<Option<Vec<ThreadgateAllowItem<S>>>>, ) -> Self
Set the allow field (optional)
Sourcepub fn maybe_allow(self, value: Option<Vec<ThreadgateAllowItem<S>>>) -> Self
pub fn maybe_allow(self, value: Option<Vec<ThreadgateAllowItem<S>>>) -> Self
Set the allow field to an Option value (optional)
Source§impl<St, S: BosStr> ThreadgateBuilder<St, S>
impl<St, S: BosStr> ThreadgateBuilder<St, S>
Sourcepub fn created_at(
self,
value: impl Into<Datetime>,
) -> ThreadgateBuilder<SetCreatedAt<St>, S>
pub fn created_at( self, value: impl Into<Datetime>, ) -> ThreadgateBuilder<SetCreatedAt<St>, S>
Set the createdAt field (required)
Source§impl<St: State, S: BosStr> ThreadgateBuilder<St, S>
impl<St: State, S: BosStr> ThreadgateBuilder<St, S>
Set the hiddenReplies field (optional)
Set the hiddenReplies field to an Option value (optional)
Source§impl<St, S: BosStr> ThreadgateBuilder<St, S>
impl<St, S: BosStr> ThreadgateBuilder<St, S>
Source§impl<St, S: BosStr> ThreadgateBuilder<St, S>
impl<St, S: BosStr> ThreadgateBuilder<St, S>
Sourcepub fn build(self) -> Threadgate<S>
pub fn build(self) -> Threadgate<S>
Build the final struct.
Sourcepub fn build_with_data(
self,
extra_data: BTreeMap<SmolStr, Data<S>>,
) -> Threadgate<S>
pub fn build_with_data( self, extra_data: BTreeMap<SmolStr, Data<S>>, ) -> Threadgate<S>
Build the final struct with custom extra_data.
Auto Trait Implementations§
impl<St, S> Freeze for ThreadgateBuilder<St, S>where
S: Freeze,
impl<St, S> RefUnwindSafe for ThreadgateBuilder<St, S>where
S: RefUnwindSafe,
impl<St, S> Send for ThreadgateBuilder<St, S>where
S: Send,
impl<St, S> Sync for ThreadgateBuilder<St, S>where
S: Sync,
impl<St, S> Unpin for ThreadgateBuilder<St, S>where
S: Unpin,
impl<St, S> UnsafeUnpin for ThreadgateBuilder<St, S>where
S: UnsafeUnpin,
impl<St, S> UnwindSafe for ThreadgateBuilder<St, 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