Struct TldrSummaryBuilder

Source
pub struct TldrSummaryBuilder<T: Clone + Debug + Default = String, S: State = Empty> { /* private fields */ }
Expand description

Use builder syntax to set the inputs and finish with build().

Implementations§

Source§

impl<T: Clone + Debug + Default, S: State> TldrSummaryBuilder<T, S>

Source

pub fn build(self) -> TldrSummary<T>
where S: IsComplete,

Finish building and return the requested object

Source

pub fn who(self, value: impl Into<T>) -> TldrSummaryBuilder<T, SetWho<S>>
where S::Who: IsUnset,

Optional (Some / Option setters).

Answers the question “Who?”

See: en.wiktionary.org/wiki/who

Source

pub fn maybe_who( self, value: Option<impl Into<T>>, ) -> TldrSummaryBuilder<T, SetWho<S>>
where S::Who: IsUnset,

Optional (Some / Option setters).

Answers the question “Who?”

See: en.wiktionary.org/wiki/who

Source

pub fn what(self, value: impl Into<T>) -> TldrSummaryBuilder<T, SetWhat<S>>
where S::What: IsUnset,

Optional (Some / Option setters).

Answers the question “What?”

See: en.wiktionary.org/wiki/what

Source

pub fn maybe_what( self, value: Option<impl Into<T>>, ) -> TldrSummaryBuilder<T, SetWhat<S>>
where S::What: IsUnset,

Optional (Some / Option setters).

Answers the question “What?”

See: en.wiktionary.org/wiki/what

Source

pub fn when(self, value: impl Into<T>) -> TldrSummaryBuilder<T, SetWhen<S>>
where S::When: IsUnset,

Optional (Some / Option setters).

Answers the question “When?”

See: en.wiktionary.org/wiki/when

Source

pub fn maybe_when( self, value: Option<impl Into<T>>, ) -> TldrSummaryBuilder<T, SetWhen<S>>
where S::When: IsUnset,

Optional (Some / Option setters).

Answers the question “When?”

See: en.wiktionary.org/wiki/when

Source

pub fn where(self, value: impl Into<T>) -> TldrSummaryBuilder<T, SetWhere<S>>
where S::Where: IsUnset,

Optional (Some / Option setters).

Answers the question “Where?”

See: en.wiktionary.org/wiki/where

Source

pub fn maybe_where( self, value: Option<impl Into<T>>, ) -> TldrSummaryBuilder<T, SetWhere<S>>
where S::Where: IsUnset,

Optional (Some / Option setters).

Answers the question “Where?”

See: en.wiktionary.org/wiki/where

Source

pub fn why(self, value: impl Into<T>) -> TldrSummaryBuilder<T, SetWhy<S>>
where S::Why: IsUnset,

Optional (Some / Option setters).

Answers the question “Why?”

See: en.wiktionary.org/wiki/why

Source

pub fn maybe_why( self, value: Option<impl Into<T>>, ) -> TldrSummaryBuilder<T, SetWhy<S>>
where S::Why: IsUnset,

Optional (Some / Option setters).

Answers the question “Why?”

See: en.wiktionary.org/wiki/why

Source

pub fn whence(self, value: impl Into<T>) -> TldrSummaryBuilder<T, SetWhence<S>>
where S::Whence: IsUnset,

Optional (Some / Option setters).

Answers the question “Whence?” (i.e., “From where?”)

See: en.wiktionary.org/wiki/whence

Source

pub fn maybe_whence( self, value: Option<impl Into<T>>, ) -> TldrSummaryBuilder<T, SetWhence<S>>
where S::Whence: IsUnset,

Optional (Some / Option setters).

Answers the question “Whence?” (i.e., “From where?”)

See: en.wiktionary.org/wiki/whence

Source

pub fn how(self, value: impl Into<T>) -> TldrSummaryBuilder<T, SetHow<S>>
where S::How: IsUnset,

Optional (Some / Option setters).

Answers the question “How?”

See: en.wiktionary.org/wiki/how

Source

pub fn maybe_how( self, value: Option<impl Into<T>>, ) -> TldrSummaryBuilder<T, SetHow<S>>
where S::How: IsUnset,

Optional (Some / Option setters).

Answers the question “How?”

See: en.wiktionary.org/wiki/how

Auto Trait Implementations§

§

impl<T, S> Freeze for TldrSummaryBuilder<T, S>
where T: Freeze,

§

impl<T, S> RefUnwindSafe for TldrSummaryBuilder<T, S>
where T: RefUnwindSafe,

§

impl<T, S> Send for TldrSummaryBuilder<T, S>
where T: Send,

§

impl<T, S> Sync for TldrSummaryBuilder<T, S>
where T: Sync,

§

impl<T, S> Unpin for TldrSummaryBuilder<T, S>
where T: Unpin,

§

impl<T, S> UnwindSafe for TldrSummaryBuilder<T, S>
where T: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.