pub struct RendererTemplate<'a> {Show 20 fields
pub other: &'a Profile,
pub component: &'a LayoutComponent,
pub config: &'a Config,
pub profile: &'a Option<Box<Profile>>,
pub lang: &'a LangFile,
pub response_count: usize,
pub questions_count: usize,
pub followers_count: usize,
pub following_count: usize,
pub friends_count: usize,
pub is_following: bool,
pub is_following_you: bool,
pub relationship: RelationshipStatus,
pub lock_profile: bool,
pub disallow_anonymous: bool,
pub require_account: bool,
pub hide_social: bool,
pub is_powerful: bool,
pub is_helper: bool,
pub is_self: bool,
}
Fields§
§other: &'a Profile
§component: &'a LayoutComponent
§config: &'a Config
§profile: &'a Option<Box<Profile>>
§lang: &'a LangFile
§response_count: usize
§questions_count: usize
§followers_count: usize
§following_count: usize
§friends_count: usize
§is_following: bool
§is_following_you: bool
§relationship: RelationshipStatus
§lock_profile: bool
§disallow_anonymous: bool
§require_account: bool
§is_powerful: bool
§is_helper: bool
§is_self: bool
Trait Implementations§
Source§impl<'a> Display for RendererTemplate<'a>
impl<'a> Display for RendererTemplate<'a>
Source§impl<'a> IntoResponse for RendererTemplate<'a>
impl<'a> IntoResponse for RendererTemplate<'a>
Source§fn into_response(self) -> Response
fn into_response(self) -> Response
Create a response.
Source§impl<'a> Template for RendererTemplate<'a>
impl<'a> Template for RendererTemplate<'a>
Source§const SIZE_HINT: usize = 703usize
const SIZE_HINT: usize = 703usize
Provides a rough estimate of the expanded length of the rendered template. Larger
values result in higher memory usage but fewer reallocations. Smaller values result in the
opposite. This value only affects
render
. It does not take effect when calling
render_into
, write_into
, the fmt::Display
implementation, or the blanket
ToString::to_string
implementation.Source§const MIME_TYPE: &'static str = "text/html; charset=utf-8"
const MIME_TYPE: &'static str = "text/html; charset=utf-8"
The MIME type (Content-Type) of the data that gets rendered by this Template
Source§fn render_into(&self, writer: &mut (impl Write + ?Sized)) -> Result<()>
fn render_into(&self, writer: &mut (impl Write + ?Sized)) -> Result<()>
Renders the template to the given
writer
fmt bufferAuto Trait Implementations§
impl<'a> Freeze for RendererTemplate<'a>
impl<'a> RefUnwindSafe for RendererTemplate<'a>
impl<'a> Send for RendererTemplate<'a>
impl<'a> Sync for RendererTemplate<'a>
impl<'a> Unpin for RendererTemplate<'a>
impl<'a> UnwindSafe for RendererTemplate<'a>
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<T> DynTemplate for Twhere
T: Template,
impl<T> DynTemplate for Twhere
T: Template,
§fn dyn_render(&self) -> Result<String, Error>
fn dyn_render(&self) -> Result<String, Error>
Helper method which allocates a new
String
and renders into it§fn dyn_render_into(&self, writer: &mut dyn Write) -> Result<(), Error>
fn dyn_render_into(&self, writer: &mut dyn Write) -> Result<(), Error>
Renders the template to the given
writer
fmt buffer§fn dyn_write_into(&self, writer: &mut dyn Write) -> Result<(), Error>
fn dyn_write_into(&self, writer: &mut dyn Write) -> Result<(), Error>
Renders the template to the given
writer
io buffer§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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