Time

Struct Time 

Source
pub struct Time<'p> { /* private fields */ }
Expand description

<time>: Time / Date element

Implementations§

Source§

impl<'p> Time<'p>

<time> items

Source

pub fn datetime<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add datetime attribute

Source

pub fn cdata<'a, V>(&mut self, text: V) -> &mut Self
where V: Into<Value<'a>>,

Add character data content

These characters will be replaced with entities:

CharEntity
&&amp;
<&lt;
>&gt;
Source

pub fn cdata_len<'a, V>(&mut self, text: V, len: usize) -> &mut Self
where V: Into<Value<'a>>,

Add character data content with a maximum character limit

CharEntity
&&amp;
<&lt;
>&gt;
Source

pub fn a(&mut self) -> A<'_>

Add A child element

Source

pub fn abbr(&mut self) -> Abbr<'_>

Add Abbr child element

Source

pub fn area(&mut self) -> Area<'_>

Add Area child element

Source

pub fn audio(&mut self) -> Audio<'_>

Add Audio child element

Source

pub fn b(&mut self) -> B<'_>

Add B child element

Source

pub fn bdi(&mut self) -> Bdi<'_>

Add Bdi child element

Source

pub fn bdo(&mut self) -> Bdo<'_>

Add Bdo child element

Source

pub fn br(&mut self) -> Br<'_>

Add Br child element

Source

pub fn button(&mut self) -> Button<'_>

Add Button child element

Source

pub fn canvas(&mut self) -> Canvas<'_>

Add Canvas child element

Source

pub fn cite_el(&mut self) -> Cite<'_>

Add Cite child element

Source

pub fn code(&mut self) -> Code<'_>

Add Code child element

Source

pub fn data(&mut self) -> Data<'_>

Add Data child element

Source

pub fn datalist(&mut self) -> DataList<'_>

Add DataList child element

Source

pub fn del(&mut self) -> Del<'_>

Add Del child element

Source

pub fn dfn(&mut self) -> Dfn<'_>

Add Dfn child element

Source

pub fn em(&mut self) -> Em<'_>

Add Em child element

Source

pub fn embed(&mut self) -> Embed<'_>

Add Embed child element

Source

pub fn i(&mut self) -> I<'_>

Add I child element

Source

pub fn iframe(&mut self) -> IFrame<'_>

Add IFrame child element

Source

pub fn img(&mut self) -> Img<'_>

Add Img child element

Source

pub fn input(&mut self) -> Input<'_>

Add Input child element

Source

pub fn ins(&mut self) -> Ins<'_>

Add Ins child element

Source

pub fn kbd(&mut self) -> Kbd<'_>

Add Kbd child element

Source

pub fn label(&mut self) -> Label<'_>

Add Label child element

Add Link child element

Source

pub fn map(&mut self) -> Map<'_>

Add Map child element

Source

pub fn mark(&mut self) -> Mark<'_>

Add Mark child element

Source

pub fn meta(&mut self) -> Meta<'_>

Add Meta child element

Source

pub fn meter(&mut self) -> Meter<'_>

Add Meter child element

Source

pub fn noscript(&mut self) -> NoScript<'_>

Add NoScript child element

Source

pub fn object(&mut self) -> Object<'_>

Add Object child element

Source

pub fn output(&mut self) -> Output<'_>

Add Output child element

Source

pub fn picture(&mut self) -> Picture<'_>

Add Picture child element

Source

pub fn progress(&mut self) -> Progress<'_>

Add Progress child element

Source

pub fn q(&mut self) -> Q<'_>

Add Q child element

Source

pub fn ruby(&mut self) -> Ruby<'_>

Add Ruby child element

Source

pub fn s(&mut self) -> S<'_>

Add S child element

Source

pub fn samp(&mut self) -> Samp<'_>

Add Samp child element

Source

pub fn script(&mut self) -> Script<'_>

Add Script child element

Source

pub fn select(&mut self) -> Select<'_>

Add Select child element

Source

pub fn slot_el(&mut self) -> Slot<'_>

Add Slot child element

Source

pub fn small(&mut self) -> Small<'_>

Add Small child element

Source

pub fn span(&mut self) -> Span<'_>

Add Span child element

Source

pub fn strong(&mut self) -> Strong<'_>

Add Strong child element

Source

pub fn sub(&mut self) -> Sub<'_>

Add Sub child element

Source

pub fn sup(&mut self) -> Sup<'_>

Add Sup child element

Source

pub fn svg(&mut self) -> Svg<'_>

Add Svg child element

Source

pub fn template(&mut self) -> Template<'_>

Add Template child element

Source

pub fn textarea(&mut self) -> TextArea<'_>

Add TextArea child element

Source

pub fn time(&mut self) -> Time<'_>

Add Time child element

Source

pub fn u(&mut self) -> U<'_>

Add U child element

Source

pub fn var(&mut self) -> Var<'_>

Add Var child element

Source

pub fn video(&mut self) -> Video<'_>

Add Video child element

Source

pub fn wbr(&mut self) -> Wbr<'_>

Add Wbr child element

Source

pub fn comment<'v, V>(&mut self, com: V) -> &mut Self
where V: Into<Value<'v>>,

Add a comment

These characters will be replaced with entities:

CharEntity
-&hyphen;
<&gt;
>&lt;
Source

pub fn raw(&mut self, trusted: impl AsRef<str>) -> &mut Self

Add raw content

WARNING: trusted is used verbatim, with no escaping; do not call with untrusted content.

Source

pub fn close(&'p mut self) -> &'p mut Page

Close the element

Adds the closing tag if necessary (e.g. </time>).

Source§

impl<'p> Time<'p>

Global attributes

Source

pub fn id<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add id attribute

Source

pub fn class<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add class attribute

Source

pub fn accesskey<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add accesskey attribute

Source

pub fn autocapitalize<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add autocapitalize attribute

Source

pub fn autocorrect<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add autocorrect attribute

Source

pub fn autofocus(&mut self) -> &mut Self

Add autofocus Boolean attribute

Source

pub fn contenteditable<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add contenteditable attribute

Source

pub fn dir<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add dir attribute

Source

pub fn draggable<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add draggable attribute

Source

pub fn enterkeyhint<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add enterkeyhint attribute

Source

pub fn exportparts<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add exportparts attribute

Source

pub fn hidden<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add hidden attribute

Source

pub fn inert(&mut self) -> &mut Self

Add inert Boolean attribute

Source

pub fn is<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add is attribute

Source

pub fn inputmode<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add inputmode attribute

Source

pub fn lang<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add lang attribute

Source

pub fn nonce<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add nonce attribute

Source

pub fn part<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add part attribute

Source

pub fn popover<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add popover attribute

Source

pub fn role<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add role attribute

Source

pub fn slot<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add slot attribute

Source

pub fn spellcheck<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add spellcheck attribute

Source

pub fn style<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add style attribute

Source

pub fn tabindex<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add tabindex attribute

Source

pub fn title<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add title attribute

Source

pub fn translate<'a, V>(&mut self, val: V) -> &mut Self
where V: Into<Value<'a>>,

Add translate attribute

Auto Trait Implementations§

§

impl<'p> Freeze for Time<'p>

§

impl<'p> RefUnwindSafe for Time<'p>

§

impl<'p> Send for Time<'p>

§

impl<'p> Sync for Time<'p>

§

impl<'p> Unpin for Time<'p>

§

impl<'p> !UnwindSafe for Time<'p>

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.